
Research
/Security News
Miasma Mini Shai-Hulud Hits ImmobiliareLabs npm Packages
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.
@resolid/cache
Advanced tools
Documentation | Framework Bundle
A fully-typed, flexible cache system for modern TypeScript projects. Supports single and batch operations, optional TTL, and pluggable storage backends. Designed for libraries, frameworks, and applications needing predictable async caching.
any.nullCache).has.dispose.pnpm add @resolid/cache
# or
npm install @resolid/cache
# or
yarn add @resolid/cache
# or
bun add @resolid/cache
import { Cacher } from "@resolid/cache";
const cache = new Cacher({ defaultTtl: 1000 });
// Single set/get
await cache.set("foo", { a: 1 });
const value = await cache.get("foo"); // -> { a: 1 }
// Check existence
const exists = await cache.has("foo"); // -> true
// Batch set/get
await cache.setMultiple({ key1: 1, key2: 2 });
const values = await cache.getMultiple(["key1", "key2"]); // -> [1, 2]
// Delete
await cache.del("foo");
await cache.delMultiple(["key1", "key2"]);
// Clear all
await cache.clear();
// Dispose store if necessary
await cache.dispose();
export interface CacheOptions {
store?: CacheStore;
defaultTtl?: number;
}
Your custom store should implement CacheStore:
export interface CacheStore {
get(key: string): Promise<string | undefined>;
set(key: string, value: string, ttl?: number): Promise<boolean>;
del(key: string): Promise<boolean>;
clear(): Promise<boolean>;
getMultiple?(keys: string[]): Promise<(string | undefined)[]>;
setMultiple?(values: Record<string, string>, ttl?: number): Promise<boolean>;
delMultiple?(keys: string[]): Promise<boolean>;
has?(key: string): Promise<boolean>;
dispose?(): Promise<void> | void;
}
MIT License (MIT). Please see LICENSE for more information.
FAQs
Type-safe Async Cache for TypeScript
The npm package @resolid/cache receives a total of 16 weekly downloads. As such, @resolid/cache popularity was classified as not popular.
We found that @resolid/cache demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.

Security News
Rolldown paused Rust React Compiler integration after a 5MB binary size increase raised concerns about shipping React-specific code to all Vite users.

Security News
/Research
Mini Shai-Hulud expands into the Go ecosystem after hitting LeoPlatform npm packages and targeting GitHub Actions workflows.