openedx / openedx/frontend-app-learning
Dissolve the model-store normalized cache
@brian-smith-tcril is already working on this.
Since Aug 5, 2026.
- Dominant language
- JavaScript
- Stars
- 70
- Forks
- 335
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 35
Description
Part of #1946 — Redux → React Query migration (Stage 1).
Goal: delete the normalized models cache now that React Query is the cache.
Tasks
- After the feature conversions, audit remaining
state.models.*selectors (generic/model-store,src/data/hooks.tsuseContextId, …) and move any residual reads to query data. - Provide a small replacement for
useContextId(read the activecourseIdfrom route/params or a context) — it currently readscourseware/courseHomeRedux state. - Delete the
generic/model-storeslice and themodelsreducer.
Verify: no state.models references remain; full suite green.
Note (size): most useModel readers (204 sites / 82 files today) fall away as courseware converts (#1976 and its siblings, esp. the metadata/sequence layers, keep them alive via the model-store bridge). Reassess this issue's residual scope once the courseware decomposition lands — it may split (e.g. useContextId replacement vs. bridge removal). The useContextId replacement also overlaps with the courseware teardown (#1976); coordinate so it isn't done twice.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.