Skip to content

chore(deps): Bump @reduxjs/toolkit from 2.13.0 to 2.14.0 in /packages/frontend - #1062

Merged
unhappychoice merged 1 commit into
mainfrom
dependabot/npm_and_yarn/packages/frontend/reduxjs/toolkit-2.14.0
Nov 9, 2026
Merged

unhappychoice merged 1 commit into
mainfrom
dependabot/npm_and_yarn/packages/frontend/reduxjs/toolkit-2.14.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Nov 9, 2026

Copy link
Copy Markdown
Contributor

Bumps @reduxjs/toolkit from 2.13.0 to 2.14.0.

Release notes

Sourced from @​reduxjs/toolkit's releases.

v2.14.0

This feature release speeds up the dispatch path and RTK Query's Api type checking, shrinks createSlice in esbuild bundles, adds RTK-owned Draft and Patch types so emitted declarations no longer reference Immer, adds removeMany({ where }) and selectByIds to the entity adapter, adds RTK Query cache entry selectors and a DevTools action sanitizer, and fixes a very long list of RTK Query lifecycle, polling, upsert, timer, hook and fetchBaseQuery bugs.

Note that we just announced our roadmap to Redux Toolkit 3.0, which includes both a large set of planned 2.x features and improvements, and planned 3.0 breaking changes. The fixes and updates in this release help pave the way for all of those efforts. We'd also appreciate feedback on the linked RTK Query usage patterns and 3.0 planned breaking changes discussion threads.

Changelog

Dispatch Performance

Every dispatched action runs through every reducer and middleware, so small costs on that path add up. We added a benchmark harness for the dispatch path and used it to find several places where RTK did work for actions it didn't care about.

createAction(...).match now compares action.type before calling isAction, so a non-matching action costs a property read. createReducer no longer allocates arrays on every dispatch to collect case and matcher reducers. Since createSlice builds its reducer with createReducer, every slice reducer gets this improvement.

The listener middleware used to copy its listener list and call every predicate for every action. It now keeps a snapshot that is rebuilt only when listeners are added or removed, and that snapshot knows which action types have type or actionCreator listeners. If an action's type isn't in that set and there are no matcher or predicate listeners, the middleware skips the loop entirely.

The RTK Query root reducer now returns the existing state for actions that none of its slices handle, instead of running all five slice reducers. It also skips rewriting a query's provided tags when the new tags are the same as the stored ones, so re-fetching a query that returns the same tags no longer creates new provided state.

Some numbers from the PR benchmarks (Node 26, ops/sec unless noted):

Scenario Before After
Listener middleware, 200 listeners, unrelated action 108K 5.34M
Listener middleware, 200 actionCreator listeners, matching action 100K 612K
createSlice, 20 slices, unrelated action 320K 394K
RTKQ store, unrelated action 352K 468K
RTKQ re-dispatch of a fulfilled query with unchanged tags, 1000 entries (ms per dispatch) 2.50 0.55

The listener middleware numbers are the biggest change, because the old cost grew with the number of listeners. Apps with a handful of listeners will see much smaller gains.

The RTK Query middleware also does less work keeping the store's subscriptions state in sync (#5499). It used to JSON-copy the whole subscriptions object and diff it with Immer every 500ms while subscriptions were changing. It now records which cache keys changed and writes one patch per key. Keys that didn't change keep their object references, so the Redux DevTools no longer receive a full copy of subscriptions on every sync. Polls, refetch() calls and tag invalidation refetches don't add subscribers, so they no longer schedule a sync at all. The visible difference: a cache key that only ever had subscribe: false requests no longer shows up as an empty {} in subscriptions.

Smaller createSlice Bundles With esbuild

createSlice references asyncThunkCreator so that create.asyncThunk works in the reducers callback. esbuild couldn't tell that the asyncThunkCreator object was free of side effects, so it always bundled createAsyncThunk along with createSlice. webpack already dropped it. We've marked it as pure, and an esbuild bundle that imports only createSlice is now about 1 kB smaller (brotli).

Faster RTK Query Api Type Checking

The Api type combines every registered module (core, React hooks, and any third-party modules) by running UnionToIntersection over the module names. TanStack Table hit the same cost with the same design, and found that writing out the known intersection and adding variance annotations helped a lot.

We've done the same thing here: Api uses the core module type directly, and ApiModules has in out variance annotations. On a test app with one ~50-endpoint createApi, type instantiations dropped 22% and check time dropped about 25% on TS 6, and about 18% on the TS 7 native preview. Third-party modules like ngrx-rtk-query saw 7-8% fewer instantiations. There are no runtime changes.

RTK-Owned Draft and Patch Types

RTK used to re-export Immer's Draft type, and used Immer's types in signatures like CaseReducer and PatchCollection. That meant the .d.ts files TypeScript generated for your slices referenced immer. With a package manager layout where immer isn't hoisted, those declarations failed to build with TS2883 (#5516). Re-exporting doesn't fix that, so RTK now declares its own Draft, WritableDraft and Patch types with the same shapes as Immer's. Emitted declarations now point at @reduxjs/toolkit instead. Our type tests check that RTK's Draft and Immer's Draft stay interchangeable, so code that mixes castDraft or current with RTK's types keeps working. We also bumped the immer dependency to ^11.2.9.

There are a few other type additions in this release:

  • ApiRootState replaces RTK Query's RootState type, which is now deprecated. RootState will be removed in 3.0.
  • TypedAddListenerAction and TypedRemoveListenerAction describe the actions that addListener and removeListener actually dispatch. The default payload type of TypedAddListener and TypedRemoveListener is now the listener options object, so addListener.match(action) no longer claims action.payload has fields like id and unsubscribe that don't exist at runtime.
  • dispatch(removeListener(...)) is typed as returning boolean and dispatch(clearAllListeners()) as returning void, matching the runtime.

... (truncated)

Commits
  • ec4a1a1 Release 2.14.0
  • 705e349 fix(toolkit): respect skipToken in infinite query triggers (#5464)
  • 6d845b7 Add simpler Basic Usage example for createListener Middleware (#4836)
  • 4bbdb3d Fix isLoading staying false when refetching after an error with no data (...
  • 3abefe7 docs(codegen): document the remaining config options (#5367)
  • 7bd07e7 docs: fix LazyInfiniteQueryTrigger docs (#5261)
  • cc1e048 docs(codegen): document the config option types in src/types.ts (#5373)
  • 9b3cb8c docs(codegen): fix malformed config options block (#5366)
  • 193bfaa docs: selectInvalidedBy for multiple cache updates across queries (#5226)
  • 687819b docs: clarify useLazyQuery data is undefined until trigger (#5348)
  • Additional commits viewable in compare view

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 [@reduxjs/toolkit](https://github.com/reduxjs/redux-toolkit) from 2.13.0 to 2.14.0.
- [Release notes](https://github.com/reduxjs/redux-toolkit/releases)
- [Commits](reduxjs/redux-toolkit@v2.13.0...v2.14.0)

---
updated-dependencies:
- dependency-name: "@reduxjs/toolkit"
  dependency-version: 2.14.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot
dependabot Bot requested a review from unhappychoice as a code owner November 9, 2026 07:44
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Nov 9, 2026
@coderabbitai

coderabbitai Bot commented Nov 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 446aed6c-c560-44ed-91d3-28bdb628159c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@netlify

netlify Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for mdts-unhappychoice ready!

Name Link
🔨 Latest commit 350341e
🔍 Latest deploy log https://app.netlify.com/projects/mdts-unhappychoice/deploys/6af179ed62cb03941036cc10
😎 Deploy Preview https://deploy-preview-1062--mdts-unhappychoice.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@unhappychoice
unhappychoice merged commit 809216d into main Nov 9, 2026
9 checks passed
@unhappychoice
unhappychoice deleted the dependabot/npm_and_yarn/packages/frontend/reduxjs/toolkit-2.14.0 branch November 9, 2026 15:20
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant