Skip to content

BlockSuite API Documentation / @blocksuite/store / Generator

Enumeration: Generator ​

Contents ​

Enumeration Members ​

AutoIncrement ​

AutoIncrement: "autoIncrement"

Warning: This generator mode will crash the collaborative feature if multiple clients are adding new blocks. Use this mode only if you know what you're doing.

Source ​

packages/store/src/workspace/store.ts:41


AutoIncrementByClientId ​

AutoIncrementByClientId: "autoIncrementByClientId"

This generator is trying to fix the real-time collaboration on debug mode. This will make generator predictable and won't make conflict

https://docs.yjs.dev/api/faq#i-get-a-new-clientid-for-every-session-is-there-a-way-to-make-it-static-for-a-peer-accessing-the-doc

Source ​

packages/store/src/workspace/store.ts:35


NanoID ​

NanoID: "nanoID"

Default mode, generator for the unpredictable id

Source ​

packages/store/src/workspace/store.ts:27


UUIDv4 ​

UUIDv4: "uuidV4"

Source ​

packages/store/src/workspace/store.ts:29


Generated using typedoc-plugin-markdown and TypeDoc