Socket
Book a DemoInstallSign in
Socket

s3-fifo-cache

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

s3-fifo-cache

More information about this algorithm you can find in [this article](https://amarchenko.dev/blog/2023-10-12-memory-cache/)

latest
Source
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

s3-fifo-cache

More information about this algorithm you can find in this article

size: 0.8Kb after gzip

How to Install

npm install --save s3-fifo-cache

How to Use

import { S3FifoCache } from 's3-fifo-cache';

const cache = new S3FifoCache(100);
cache.set("key", "value");
cache.set("key2", "value");
cache.get("key") // -> "value"

cache.has("key") // -> true

cache.delete("key");
cache.get("key") // -> undefined

cache.clear();

Keywords

cache

FAQs

Package last updated on 01 Jan 2024

Did you know?

Socket

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.

Install

Related posts