-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DATAP-1208 Convert reducers to RTK slices #482
Conversation
…m/cfpb/ccdb5-ui into WW-DATAP-1208-reducers-use-slices
615106a
to
2d0a445
Compare
21c95bd
to
7192be5
Compare
59e2d92
to
58b7acb
Compare
Nothing needed from this comment, just a suggestion. Now that we're on RTK, do you think RTK Query could be a good option for our API calls? Seems like it would eliminate a lot of the custom structure we've put in place to create and make API calls. May be something to look into down the line. |
Yes, great suggestion. I'm all for anything that reduces custom code and not reinventing the wheel! |
Also doesn't look like that RTK's |
complaints.spec fix fixing unit test coverage updating unit tests update unit test, remove dead code update selectors, fix trends test fixing a test remove unused isfromexternal param comment out unused selectors remove unused code remove unused code remove unused code remove unused code adding unit test for search component fix comment updating test fix cypress test in doc detail view fixing test fixing some unit tests revert cypress fixes fixing tests adding pager reset when date change fixing test fixing unit tests fixing unit tests fixing unit tests add dist squash fixtures, remove mutation observer, doesnt seem like it is needed squash update gitignore move test files fixing test setup, update coverage package.json fixing tests refactoring payload reducer fix typeahead bug fixes, fixing pagination, hide when no results linting update dist update date model, correct time zone accessiblity fixes for date range, expand/collapse filter linting complaint and apostrophe fix remove breaks fixing tests updating build update feedback cleanup update stuff cleanup
…-1208-reducers-use-slices # Conflicts: # dist/ccdb5.css # dist/ccdb5.css.map # dist/ccdb5.js # dist/ccdb5.js.map # src/components/Filters/DateRanges.js # src/components/List/ComplaintCard/ComplaintCard.js # src/components/List/ListPanel/ListPanel.js # src/components/Map/MapToolbar.js # src/components/Map/TileChartMap/TileChartMap.js # src/components/RefineBar/ChartToggles.js # src/components/Search/Pill.js # src/components/Search/SearchBar.js # src/components/Trends/LensTabs.js # src/components/Trends/TrendDepthToggle.js
b6f136d
to
ec3a36e
Compare
Redux Toolkit divides redux state into "slices", which make managing state easier and more efficient. Explorer was converted to use slices, but CCDB hadn't yet. This is a PR converting all the reducers to slices, updating tests to accommodate the changes, and refactoring code where necessary, mainly in dispatches. Most of the content of the actions directory was removed since it's handled in the extraReducers piece of the slices, but where it seemed to make more sense to leave them as is, I did.
Removals
Changes
Testing
yarn test
: All tests should passNotes
Todos
Checklist