A configuration object for a perishable storage implementation.

interface IPerishableStorageConfig {
    errorOnFailure?: boolean;
    maxAge?: number;
    prefix?: string;
    storageDriver?: Storage;
}

Hierarchy (view full)

Properties

errorOnFailure?: boolean

Whether to throw an error if the storage implementation is not available.

maxAge?: number

The maximum time in milliseconds before which items expire and are removed (default: 60 * 60 * 1000).

prefix?: string

An optional string to prefix the storage key.

storageDriver?: Storage

The storage driver to use.