@forge/cache
TypeScript icon, indicating that this package has built-in type declarations

0.7.3 • Public • Published

Library for Forge environment.

Usage example:

import cache from "@forge/cache";

const cacheClient = cache.connect();

await cacheClient.set("hello", "3", { ttlSeconds: 10 });

const result = await cacheClient.setIfNotExists("hello", "3", { ttlSeconds: 10 });

const result = await cacheClient.get("hello");

const result = await cacheClient.getAndSet("hello", "3", { ttlSeconds: 10 });

const result = await cacheClient.incrementAndGet("hello");

const result = await cacheClient.decrementAndGet("hello");

const result = await cacheClient.delete("hello");

const result = await cacheClient.scan("hello*", { cursor: "10", count: 10 });

const result = await cacheClient.leftPush("list", "3");

const result = await cacheClient.rightPop("list");

const result = await cacheClient.listLength("list");

Readme

Keywords

none

Package Sidebar

Install

npm i @forge/cache

Weekly Downloads

413

Version

0.7.3

License

UNLICENSED

Unpacked Size

28 kB

Total Files

11

Last publish

Collaborators

  • danwinterwijntjes
  • atlassian-cicd