API Reference
indexedDbKv()
Creates an IndexedDB-backed KV storage tier.
Import
import { indexedDbKv } from "@graphrefly/ts/storage/browser";
Signature
function indexedDbKv(
spec: IndexedDbBackendSpec,
opts: IndexedDbKvOptions<T> = {},
): KvStorageTier<T>
Parameters
| Parameter | Type | Description |
|---|---|---|
spec | IndexedDbBackendSpec | spec value used by the helper. |
opts | IndexedDbKvOptions<T> | Options that configure the helper. |
Returns
A KvStorageTier<T> value.
Example
import { indexedDbKv } from "@graphrefly/ts/storage/browser";
Source
packages/ts/src/storage/browser.ts