Skip to content

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

Closed

Description

@aduth

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 )"

Activity

  1. added
    [Type] Task
    [Package] Data
    [Type] Performance
    [Type] Code Quality
    on Dec 14, 2018
  2. gziolo commented on Dec 17, 2018

    @gziolo
    Member

    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

  3. aduth commented on Dec 17, 2018

    @aduth
    MemberAuthor

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

  4. aduth commented on Dec 18, 2018

    @aduth
    MemberAuthor

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

  5. aduth commented on Feb 14, 2019

    @aduth
    MemberAuthor

    Closing based on referenced subtasks having been merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Package] Data[Type] Code Quality[Type] Performance[Type] Task

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions