MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / anchor

Function anchor

src/lib/editorManager.js:1241–1247  ·  view source on GitHub ↗

* Get current selection anchor * @returns {number} Anchor position

()

Source from the content-addressed store, hash-verified

1239 * @returns {number} Anchor position
1240 */
1241 get anchor() {
1242 try {
1243 return editor.state.selection.main.anchor;
1244 } catch (_) {
1245 return 0;
1246 }
1247 },
1248
1249 /**
1250 * Get current selection range

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected