API reference > @kontsedal/olas-persist > indexedDbAdapter
indexedDbAdapter() function
IndexedDB-backed StorageAdapter. Async on every operation; cross-tab change notifications layered via BroadcastChannel in a browser (IDB has no native change event, so external IDB writes by code that doesn't go through this adapter are *not* observed). When no IDBFactory is available (SSR, restricted environments), every method resolves to a no-op.
Storage is a single key/value object store inside a single database; fine for the persisted-signal use case createPersisted is built around. For larger or schema-shaped data, write a custom adapter against your own IDB layout.
Signature:
typescript
export declare function indexedDbAdapter(options?: IndexedDbAdapterOptions): StorageAdapter;Parameters
Parameter | Type | Description |
|---|---|---|
options | (Optional) |
Returns: