key-file-storage
Version:
Simple key-value storage directly on file system, maps each key to a separate file.
14 lines (13 loc) • 593 B
TypeScript
import { KeyFileStorage } from './src/key-file-storage';
/**
* Returns an instance of `key-file-storage` store to access the file system.
* @param path The root storage path on the file system:
* * For example `'./the/path/to/data'`
* @param caching The selected cache configuration:
* * `true` *(By default)* for unlimited cache,
* * `false` to disable caching,
* * `n: number` to cache the latest **n** accessed keys.
*/
declare function keyFileStorage(path: string, caching?: number | boolean): KeyFileStorage;
export default keyFileStorage;
export { keyFileStorage };