@allior/cache
v0.0.3
Published
Little cache system
Readme
Allior Cache
Usage
import { AlliorCache } from "@allior/wmake-utils";
const cache = new AlliorCache<string, number>(100); // set limit to 100 keypairs
cache["user:1"] = 42; // write
const value = cache["user:1"]; // read
const has = "user:1" in cache; // exists check
console.log(value); // 42
console.log(has); // true