Skip to content
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

Editor: Update withDispatch-wrapped components to use registry if applicable #12890

Closed
4 tasks done
aduth opened this issue Dec 14, 2018 · 4 comments
Closed
4 tasks done
Labels
[Package] Data /packages/data [Type] Code Quality Issues or PRs that relate to code quality [Type] Performance Related to performance efforts [Type] Task Issues or PRs that have been broken down into an individual action to take
Milestone

Comments

@aduth
Copy link
Member

aduth commented Dec 14, 2018

Previously: #11851

With the changes introduced by #11851, we should seek to refactor components which provide data through withSelect for the sole purpose of satisfying a dispatch callback. These components instead should use the new registry argument.

Upon investigation, these are the components I discovered to be refactored:

The workflow for discovering these was to search the codebase for and sort through results of withDispatch with a mapping which makes use of the second ownProps argument.

Searching 1670 files for "withDispatch( ( dispatch, ownProps )"
@aduth aduth added [Type] Task Issues or PRs that have been broken down into an individual action to take [Package] Data /packages/data labels Dec 14, 2018
@aduth aduth added [Type] Performance Related to performance efforts [Type] Code Quality Issues or PRs that relate to code quality labels Dec 14, 2018
@gziolo
Copy link
Member

gziolo commented Dec 17, 2018

Did you search for withDispatch( ( dispatch, There are 37 matches which we might want to verify, too:

screen shot 2018-12-17 at 14 53 36

@aduth
Copy link
Member Author

aduth commented Dec 17, 2018

I did not! The in-place destructuring could certainly qualify. Let's update the original comment with new items as they're discovered.

@aduth
Copy link
Member Author

aduth commented Dec 18, 2018

I updated the original comment with two more from a withDispatch( ( dispatch, { search.

@aduth
Copy link
Member Author

aduth commented Feb 14, 2019

Closing based on referenced subtasks having been merged.

@aduth aduth closed this as completed Feb 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Data /packages/data [Type] Code Quality Issues or PRs that relate to code quality [Type] Performance Related to performance efforts [Type] Task Issues or PRs that have been broken down into an individual action to take
Projects
None yet
Development

No branches or pull requests

2 participants