Installation
npm install --save @types/chenyfan__cache-db
Summary
This package contains type definitions for @chenyfan/cache-db (https://www.npmjs.com/package/@chenyfan/cache-db).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chenyfan__cache-db.
index.d.ts
declare namespace CacheDB {
interface Config {
type: "json" | "arrayBuffer" | "blob" | "text" | string;
}
type ReadMethodData = object | ArrayBuffer | Blob | string | null;
type WriteValue =
| ReadableStream
| Blob
| ArrayBufferView
| ArrayBuffer
| FormData
| URLSearchParams
| string;
}
declare class CacheDB {
constructor(namespace?: string, prefix?: string);
namespace: string;
prefix: string;
read(key: string, config?: CacheDB.Config): Promise<CacheDB.ReadMethodData>;
write(
key: string | number | boolean,
value: CacheDB.WriteValue,
config?: CacheDB.Config,
): Promise<boolean>;
delete(key: string): Promise<boolean>;
}
export = CacheDB;
export as namespace CacheDB;
Additional Details
- Last updated: Mon, 06 Nov 2023 22:41:05 GMT
- Dependencies: none
Credits
These definitions were written by AHdark.