Skip to content

Commit e9ff069

Browse files
committed
feat: add instanceId property to editor
1 parent a07eea2 commit e9ff069

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

packages/core/src/Editor.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,11 @@ export class Editor extends EventEmitter<EditorEvents> {
6464

6565
public extensionStorage: Record<string, any> = {}
6666

67+
/**
68+
* A unique ID for this editor instance.
69+
*/
70+
public instanceId = Math.random().toString(36).slice(2, 9)
71+
6772
public options: EditorOptions = {
6873
element: document.createElement('div'),
6974
content: '',

0 commit comments

Comments
 (0)