Redux & Redux Toolkit

Six isolated examples (easy → hard). Each route has its own configureStore — copy a folder for production patterns. Use the Redux DevTools browser extension while clicking through demos. Interview Q&A: Redux & RTK notes.

LevelExampleConceptsOpen
1Example 1 — CountercreateSlice, configureStore, useDispatch, useSelector, ImmerOpen
2Example 2 — Todos + filterpayload actions, multiple slices, createSelectorOpen
3Example 3 — createAsyncThunkcreateAsyncThunk, extraReducers, loading / error stateOpen
4Example 4 — Login flowauth slice, rejectWithValue, login interview flowOpen
5Example 5 — RTK QuerycreateApi, fetchBaseQuery, mutations, cache tagsOpen
6Example 6 — Production patternslistener middleware, multi-feature store, typed hooksOpen

How to study

  1. Read the page intro, then open the listed source files on each example.
  2. Example 4 is the login interview walkthrough — compare with Example 3 for generic async API patterns.
  3. Example 5 shows the same auth API with RTK Query instead of manual thunks.

Markdown notes (repo)

Notes live next to each example as NOTES.md.

  • Track overviewsrc/app/learn/redux/NOTES.md
  • Example 1 — Countersrc/app/learn/redux/example-1-counter/NOTES.md
  • Example 2 — Todos + filtersrc/app/learn/redux/example-2-todos/NOTES.md
  • Example 3 — createAsyncThunksrc/app/learn/redux/example-3-async-thunk/NOTES.md
  • Example 4 — Login flowsrc/app/learn/redux/example-4-login/NOTES.md
  • Example 5 — RTK Querysrc/app/learn/redux/example-5-rtk-query/NOTES.md
  • Example 6 — Production patternssrc/app/learn/redux/example-6-patterns/NOTES.md