Skip to main content
Home

Built and signed on GitHub Actions

Common types and utilities for Pluggable Storage Modules

This package works with Cloudflare Workers, Node.js, Deno, Bun, Browsers
This package works with Cloudflare Workers
This package works with Node.js
This package works with Deno
This package works with Bun
This package works with Browsers
JSR Score
100%
Published
2 months ago (0.8.0)
f
copyItems

Default implementation of copyItems for stores that might not implement it, or for copying between stores.

f
fromStrKey

Convert an array of strings to a StorageKey

f
toStrKey

Convert a StorageKey to an array of strings

f
moveItems

Default implementation for moveItems

f
open

Ensure that the underlying storage has been opened and is empty

f
testClearItems

Test the clearItems() function of the given storage module.

f
testCopyItems

Test the copyItems() function of the given storage module.

f
testGetItem

Test the getItem() function of the given storage module, this must be called after testSetItem.

f
testHasItem

Test the hasItem() function of the given storage module, this must be called after testSetItem.

f
testIsWritable

Test the isWritable() function of the given storage module.

f
testListItems

Test the listItems() function of the given storage module, this must be called after testSetItem.

f
testMoveItems

Test the moveItems() function of the given storage module.

f
testOrdering

Test the storage module list items ordered by key, and supports listing in reverse. This test is optional for a storage module.

f
testRemoveItem

Test the removeItem() function of the given storage module, this must be called after testSetItem.

f
testSetItem

Test the setItem() function of the given storage module.

f
testUrl

Test the url() function of the given storage module.

f
testUrlForPrefix

Test the url() function of the given delegated storage module with a key prefix.

T
Awaitable

A value that may be awaited.

T
CompleteStorageModule

Describes a storage module that provides all functions

I
DelegatedStore

Additional functions for a store that delegates to one or more other stores

I
ExtendedStorageModule

Describes an optional extended interface that may be provided by a storage module

I
MinimalStorageModule

Describes the minimal interface that must be provided by each storage module

T
StorageKey

A key for an item in a store.

T
StorageModule

Describes the common interface provided by each storage module

New Ticket: Report package

Please provide a reason for reporting this package. We will review your report and take appropriate action.

Please review the JSR usage policy before submitting a report.