web-state-redux-toolkit
Installation
SKILL.md
Redux Toolkit Patterns
Quick Guide: Redux Toolkit earns its place where state is complex enough to want DevTools, middleware, time-travel or normalised entities.
configureStoreandcreateSliceare the whole authoring surface; Immer makes reducers read as mutations while staying immutable. RTK 2.0 removed the object form ofextraReducersand the array forms ofmiddlewareandenhancers— all three are callbacks now — andAnyActiongave way toUnknownAction.
Detailed Resources:
- examples/core.md —
configureStore,createSlice, Immer reducers, prepare callbacks - examples/typed-hooks.md —
useAppSelector/useAppDispatchvia.withTypes() - examples/rtk-query.md —
createApi, endpoints, cache tags, invalidation - examples/entity-adapters.md — normalised collections and their selectors
- examples/async-thunks.md —
createAsyncThunkand its lifecycle actions - examples/selectors.md —
createSelectorand memoisation - examples/rtk-2-features.md —
combineSlices, inline selectors,buildCreateSlice - examples/middleware.md — custom middleware
- examples/testing.md — testing reducers, thunks and selectors
- examples/persistence.md — persisting the store across sessions
- reference.md — anti-pattern code, TypeScript recipes, RTK 2.0 migration, performance notes