Skip to content

chore(deps): bump reselect from 4.1.8 to 5.3.0 - #1388

Closed
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/npm_and_yarn/reselect-5.3.0
Closed

chore(deps): bump reselect from 4.1.8 to 5.3.0#1388
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/npm_and_yarn/reselect-5.3.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Aug 31, 2026

Copy link
Copy Markdown
Contributor

Bumps reselect from 4.1.8 to 5.3.0.

Release notes

Sourced from reselect's releases.

v5.3.0

This feature release adds a maxSize option to weakMapMemoize to bound cache growth, adds a new development-mode check that warns when a selector's cache grows without bound, improves memoization performance, removes the experimental unstable_autotrackMemoize, and updates our TypeScript support matrix and documentation.

Changelog

maxSize Option for weakMapMemoize

weakMapMemoize has been the default memoizer since v5.0, and its main benefit is the infinite cache size. Prior to v5, selector instances had a default cache size of 1, which meant having to create unique selector instances per component when sharing selectors that took varying arguments like IDs. weakMapMemoize memoizes based on all arguments, so it eliminated the extra setup work and just stores all cached values.

However, that behavior can also effectively turn into a memory leak depending on what state and arguments are passed in and how they're used in the UI.

weakMapMemoize now accepts a maxSize option that bounds this growth:

const getVisibleItems = weakMapMemoize(
  (items, from, to) => items.slice(from, to),
  { maxSize: 100 }
)

This shares the same maxSize option name as the earlier lruMemoize, but has different behavior. Rather than an LRU eviction, this is a "generational" swap (kind of like a double buffer). When the cache hits its max size, it's swapped out with an empty version and starts over at 0 entries. So, there's effectively at most 2 * maxSize items in memory at any time. If maxSize is not enabled, there's no additional logic or performance overhead. If you do need LRU-style behavior, use lruMemoize instead.

Note that bounding a createSelector selector requires passing maxSize in both memoizeOptions and argsMemoizeOptions, since the two memoization levels have separate caches. See the maxSize docs for details.

Thanks to @​veksa for proposing this in PR #761 and providing memory test infrastructure that helped verify this behavior.

New cacheSizeCheck Dev-Mode Check

We've also added an additional dev-mode check alongside the existing inputStabilityCheck and identityFunctionCheck. If a memoized function has accumulated over 1000 values for the same args, it logs a warning with the function name and stack trace. By default this runs once per function. Unlike the other two checks, it can only be configured globally, via setGlobalDevModeChecks({ cacheSizeCheck: 'always' | 'once' | 'never' })

Performance Improvements

We've revamped our own performance benchmark suite to give better results with more precision and less noise. That's helped verify some additional performance improvements.

  • weakMapMemoize now returns early on a cache hit instead of continuing through bookkeeping
  • lruMemoize's cache lookup was simplified to eliminate unnecessary allocations

These are small wins on already-fast paths, but did show modest improvements.

Removal of unstable_autotrackMemoize

We've removed the experimental unstable_autotrackMemoize export. It was added in v5.0 as an experiment in Glimmer-style dependency tracking, never left unstable_, and as far as we can tell never saw real adoption. If you were using it, switch to weakMapMemoize (the default) or lruMemoize.

TypeScript Support

Our TypeScript support matrix is now 5.6 and up, matching DefinitelyTyped, and CI now tests against TS 6.0.

We've documented on the selector fields that a full cache reset requires clearing both memoization levels: selector.clearCache() plus selector.memoizedResultFunc.clearCache().

We improved types handling in cases where TS strict mode is off (but please migrate to strict behavior as soon as possible!)

... (truncated)

Commits
  • 73e2049 Release 5.3.0
  • 20a91eb Merge pull request #785 from reduxjs/docs/weakmap-hotpath-docs
  • 24bb579 Add docs note on complex selectors and state
  • c57b567 Merge pull request #784 from reduxjs/feature/remove-autotrack
  • 0b0b30b Remove experimental autoTrackMemoize
  • 96d81d3 Merge pull request #760 from veksa/fix/569-clearing-selector-cache
  • 5f51f11 types: document dual cache on selector fields and add clearCache type test (#...
  • 0a64b33 docs: clarify how to fully clear a selector's cache (#569)
  • 77a5b6a Merge pull request #783 from reduxjs/feature/weakmap-maxsize
  • 0f785da Document weakMap maxSize option
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by GitHub Actions, a new releaser for reselect since your current version.


Dependabot compatibility score

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 show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @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 [reselect](https://github.com/reduxjs/reselect) from 4.1.8 to 5.3.0.
- [Release notes](https://github.com/reduxjs/reselect/releases)
- [Changelog](https://github.com/reduxjs/reselect/blob/master/CHANGELOG.md)
- [Commits](reduxjs/reselect@v4.1.8...v5.3.0)

---
updated-dependencies:
- dependency-name: reselect
  dependency-version: 5.3.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Aug 31, 2026
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Inactive PR

@github-actions github-actions Bot added the Stale label Sep 3, 2026
@github-actions github-actions Bot closed this Sep 4, 2026
@github-actions
github-actions Bot deleted the dependabot/npm_and_yarn/reselect-5.3.0 branch September 4, 2026 05:32
@dependabot @github

dependabot Bot commented on behalf of github Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

OK, I won't notify you again about this release, but will get in touch when a new version is available. If you'd rather skip all updates until the next major or minor version, let me know by commenting @dependabot ignore this major version or @dependabot ignore this minor version. You can also ignore all major, minor, or patch releases for a dependency by adding an ignore condition with the desired update_types to your config file.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code Stale

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant