Skip to content

Bookmark

Unofficial

A bookmark marking a specific position in the editor document that tracks changes.

Import:

import type { Bookmark } from '@obsidian-typings/obsidian-catalyst-latest';

Signature:

export interface Bookmark

Properties

Property Type Description
assoc number Association direction for the bookmark (-1 for left, 1 for right).
cm CodeMirrorEditor The CodeMirror editor instance this bookmark belongs to.
id number Unique identifier for this bookmark.
offset number Character offset of the bookmark within its line.

Methods

Method Returns Description
clear() void Remove this bookmark from the editor.
find() EditorPosition | null Find the current position of this bookmark, or null if cleared.
update(changeDesc) void Update the bookmark position in response to a document change.

Links to this page: