ApiCoreFunctions
Function: folderStores()
function folderStores(directory, options?): StoreFactory;Defined in: packages/core/src/node/stores.ts:70
Stores in a data folder several apps and devices share (spec 05 §14).
The folder holds the registry, sealed, and each space as segments, the way
a mirror keeps one in a bucket (folder). Everything else is this device's
own, in local. Nothing else is read from the folder: whoever can write it
could plant a writer id or a key's last place for this device to take.
Parameters
| Parameter | Type | Description |
|---|---|---|
directory | DirectoryHandleLike | - |
options? | { basePath?: string; local?: StoreFactory; localKey?: CryptoKey | null; } | - |
options.basePath? | string | Where this account's data starts, e.g. accounts/<id>/stores |
options.local? | StoreFactory | Where this device keeps its own stores, outside the folder. Default: IndexedDB under minca-pod:<basePath>. Required without IndexedDB: in memory, a restart would sign at a place it signed before. |
options.localKey? | CryptoKey | null | Seals the registry. Without it nothing is sealed. |