# DocumentCompareSnapshotOptions

interface

Options for [`makeSnapshot`](module_ai_toolkit_documentcompare-DocumentCompare.md#function-makeSnapshot).

<a id="properties"></a>

## Properties

<a id="member-selection"></a>

### `selection?: Iterable<ModelRange, any, any>`

Ranges to capture with the snapshot as the user's selection. Must not intersect. By default, no selection is captured.

<a id="member-useDataIds"></a>

### `useDataIds?: boolean`

Whether the snapshot content is stamped with `data-id` attributes.

With `true`, every structural element of the serialized data gets a `data-id` attribute. Later, the comparison uses these IDs to pair the elements of the snapshot and the processed data. The processing must retain the data IDs on the elements that were kept. New elements should not get any ID.

With `false`, no `data-id` is written, and the comparison pairs the elements only by their content similarity instead. Use it when the processing cannot retain the IDs.

Defaults to `true`

---

Full index of the CKEditor 5 API reference: [llms.txt](llms.txt)
