Skip to content

Interface: StorageAdapter ​

Defined in: storage/create-storage.ts:36

The store under a StorageInstance, which holds the strings. The keys it is given carry the prefix.

Properties ​

PropertyTypeDescriptionDefined in
getItem(key) => string | nullReturns the raw string, or null when there is none.storage/create-storage.ts:38
keys() => string[]Returns every key the store holds, prefixes included.storage/create-storage.ts:42
removeItem(key) => void-storage/create-storage.ts:40
setItem(key, value) => void-storage/create-storage.ts:39
watch?(onChange) => UnsubscribeReports the changes made outside the adapter, with null when everything changed at once, and returns the function that stops listening. It is called only when crossTab is on.storage/create-storage.ts:47

Released under the MIT License.