Closed Bug 1750952 Opened 2 years ago Closed 2 years ago

Move selectors from reducers modules to selectors modules

Categories

(DevTools :: Debugger, task)

task

Tracking

(firefox98 fixed)

RESOLVED FIXED
98 Branch
Tracking Status
firefox98 --- fixed

People

(Reporter: ochameau, Assigned: ochameau)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

Currently, debugger's reducer modules are hosting many selector methods which are directly used by the React Components.

For example all these methods of the sources reducer:
https://searchfox.org/mozilla-central/rev/d4b9c457db637fde655592d9e2048939b7ab2854/devtools/client/debugger/src/reducers/sources.js#583-1036

It would probably help the long term maintenance of this by having a clearer split between:

  • reducers, which only implement the update method
  • selectors, which are querying the state with a particular layout for the queried data

Doing this might actually help revisit the selectors and improve their performance.
This would probably help highlight the number of selectors used, their inter-dependencies and help craft selectors that memoize more frequently.

Depends on: 1751031
Depends on: 1751032
Depends on: 1751851
Depends on: 1751926
Depends on: 1751932
Depends on: 1751933
Assignee: nobody → poirot.alex
Status: NEW → ASSIGNED
Attachment #9260632 - Attachment description: Bug 1750952 - [devtools] Stop exposing all reducers from selectors → Bug 1750952 - [devtools] Stop exposing all reducers from selectors.
Blocks: 1749767
Pushed by apoirot@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/22568bcf2d59
[devtools] Migrate all expressions selectors to a selector module. r=bomsy
https://hg.mozilla.org/integration/autoland/rev/4c536f66f404
[devtools] Stop exposing all reducers from selectors. r=bomsy
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 98 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: