A much much simpler memorizing utility
import memo from '@avcs/memo';
const memorizedFunction = memo(originalFunction, { onlyOnce?: boolean })
// optionally you can do this
memorizedFunction.reset()
- Supports any number of arguments
- Arguments and return values can be literally anything and everything
- Works by reference, so does not support
different objects/arrays/functions
withsame values