Skip to content

A simple memoize implementation using tree-based caching with support for nested array arguments

Notifications You must be signed in to change notification settings

cristiancavalli/memoize

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

memoize

A simple memoize implementation using tree-based caching with support for nested array arguments [Just for fun]

To test

> cd memoize
> npm test

To Use

const memoize = require('./index.js');
const cached = memoize(a => a + 2);
cached(1);
cached(2);
// This return will consist of the
// cached result of the prior,
// same-argument invocation
cached(1);

About

A simple memoize implementation using tree-based caching with support for nested array arguments

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published