Move file search state from redux to react component
Categories
(DevTools :: Debugger, task)
Tracking
(firefox115 fixed)
Tracking | Status | |
---|---|---|
firefox115 | --- | fixed |
People
(Reporter: ochameau, Assigned: ochameau)
References
Details
Attachments
(4 files)
The data currently store in redux related to the search-in-file bar in bottom of the source text content is actually specific to SearchBar component.
It isn't being used anywhere else. So there is no real value in having it being stored in redux.
It created unecessary store updates making the overall application slower, as all mapStateToProps function will be called even if we know all changes made to this data will be specific to this unique component.
This will help address bug 1822295 as the React component state will be cleared on thread removal as the selected source will be cleared if it relates to a removed thread. Nullifying the selected source will cleare this component's state.
Assignee | ||
Comment 1•1 years ago
|
||
As we have various search component, it would help to be slightly more precise
and this helps connect this component with "file" search selectors, reducers, actions.
Updated•1 years ago
|
Assignee | ||
Comment 2•1 years ago
|
||
Assignee | ||
Comment 3•1 years ago
|
||
Assignee | ||
Comment 4•1 years ago
|
||
As these results are only used within this react component,
we can make it become part of its state.
This will reducer number of Redux store updates and improve performances.
This also simplify redux management as we no longer have to try to clear
results on thread/target removal. The source will be removed and source unselected
and SearchInFileBar will be destroyed.
Comment 6•1 year ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/0b2aeb734e07
https://hg.mozilla.org/mozilla-central/rev/36753177365f
https://hg.mozilla.org/mozilla-central/rev/8414e854a500
https://hg.mozilla.org/mozilla-central/rev/3406f9953901
Description
•