delete() returns boolean indicating whether anything was deleted
7.2.0
Add reason to dispose() calls.
7.1.0
Add ttlResolution option
Add ttlAutopurge option
v7 - 2022-02
This library changed to a different algorithm and internal data structure
in version 7, yielding significantly better performance, albeit with
some subtle changes as a result.
If you were relying on the internals of LRUCache in version 6 or before, it
probably will not work in version 7 and above.
Specific API Changes
For the most part, the feature set has been maintained as much as possible.
However, some other cleanup and refactoring changes were made in v7 as
well.
The set(), get(), and has() functions take options objects
instead of positional booleans/integers for optional parameters.
size can be set explicitly on set().
cache.length was renamed to the more fitting cache.size.
Deprecations:
stale option -> allowStale
maxAge option -> ttl
length option -> sizeCalculation
length property -> size
prune() method -> purgeStale()
reset() method -> clear()
The objects used by cache.load() and cache.dump() are incompatible
with previous versions.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps lru-cache from 6.0.0 to 7.3.1.
Changelog
Sourced from lru-cache's changelog.
... (truncated)
Commits
13cd6ba
7.3.17e7856e
fix bug when tail moves during initial fillea96cd5
7.3.0496faf7
set() returns this, delete() returns boolean73b7f83
Add disposeAfter() optionb77d8e9
fix typo in readmec98f201
fix incorrect syntax highlighting in readmedf15fd1
remove travis7c94cb6
test for pop()385bf73
7.2.0Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)