Comparing version 1.2.0 to 1.3.0
@@ -6,2 +6,3 @@ import KVNamespaceApi, { NamespaceResponse } from './kvNamespaceApi'; | ||
import KVTable from './kvTable'; | ||
import KVItem from './kvItem'; | ||
interface KVApiArgs { | ||
@@ -40,4 +41,4 @@ kvNamespaceApi: KVNamespaceApi; | ||
fetch: (path: string, init: RequestInit) => Promise<any>; | ||
readKeyValuePair: (key: string) => Promise<NamespaceResponse<any>>; | ||
writeKeyValuePair: (key: string, value: string, metadata?: any, options?: SetOptions) => Promise<any>; | ||
readKeyValuePair: <T>(key: string) => Promise<NamespaceResponse<T>>; | ||
writeKeyValuePair: (key: string, value: string, metadata?: any, options?: SetOptions) => Promise<NamespaceResponse<void>>; | ||
writeMultipleKeyValuePairs: (keyValues: KeyValuePair[]) => Promise<NamespaceResponse<void>>; | ||
@@ -50,3 +51,4 @@ deleteKeyValuePair: (key: string) => Promise<NamespaceResponse<void>>; | ||
useKVBig: (options?: KVBigOptions) => KVBig; | ||
useKVItem: <T>(key: string) => KVItem<T>; | ||
} | ||
export {}; |
{ | ||
"name": "superkv", | ||
"version": "1.2.0", | ||
"version": "1.3.0", | ||
"author": "g45t345rt", | ||
@@ -21,2 +21,3 @@ "license": "ISC", | ||
"test:kvBatch": "jest -i test/kvBatch.test.ts", | ||
"test:kvItem": "jest -i test/kvItem.test.ts", | ||
"build": "ts-node build.ts && tsc --emitDeclarationOnly --outDir dist", | ||
@@ -23,0 +24,0 @@ "prepublishOnly": "npm run build" |
@@ -17,5 +17,5 @@ # SUPERKV - Supercharge Clouflare KeyValue store (experimental) | ||
- I made this because I simply wanted to have more control over the KV storage. | ||
- I made this because I want more control with KV storage. | ||
- If you have ideas or you know how to optimize/fix things please help :) | ||
- KV uses ascending lexicographical order use ULID to sort descending <https://www.npmjs.com/package/ulidx> | ||
- KV uses ascending lexicographical order. You have to use ULID to sort descending <https://www.npmjs.com/package/ulidx> | ||
- I have no prior knowledge in making a tool for data management and this is the best I could come up with. | ||
@@ -22,0 +22,0 @@ |
19634
12
307