defineSharedStore
defineSharedStore<
Store>(_storeName): typeofSharedStore
Defined in: core/src/document.ts:45
The main persistence & network sync object. A SharedStore is a YJS document wrapped in valtio state and tracked by a solidjs store.
- To read reactively, use
storeSnapshot. It’s a Solid store. - To change the state and sync it across YJS, use
stateand mutate a field.
Type Parameters
Section titled “Type Parameters”Store extends object = any
Parameters
Section titled “Parameters”_storeName
Section titled “_storeName”string
Returns
Section titled “Returns”typeof SharedStore