> For the complete documentation index, see [llms.txt](/llms.txt).
> The full corpus is at [llms-full.txt](/llms-full.txt).

# isActiveAnnotation

> **isActiveAnnotation**(`annotation`, `options?`): `EditorSelector`\<`boolean`\>

Defined in: selector.is-active-annotation.ts:13

Check whether an annotation is active in the given `snapshot`.

## Parameters

### annotation

`string`

### options?

#### mode?

`"partial"` \| `"full"`

Choose whether the annotation has to cover the entire selection
(`'full'`) or whether the selection covering at least one character
of the annotation suffices (`'partial'`). With a collapsed
selection the modes agree: the annotation is active when the caret
sits inside it, not at its edges.

Defaults to `'full'`

## Returns

`EditorSelector`\<`boolean`\>