Skip to content

Remove class components and HOCs #386

@jthrilly

Description

@jthrilly

The use of compose patterns, and class components is potentially a blocker for updating to React 19/Next 15.

While HOCs still work, the recompose library has been depreciated since 2018. The idea of HOCs can be neatly replaced with hooks, which are equally composable.

Key issues we want to address:

  • Ideally, we want to remove the recompose dependency entirely
  • In particular, we want to focus on instances where we use things like withState and withHandlers, since these should be simple to replace with hooks.
  • Keep in mind opportunities for custom hooks when we have repetitive patterns using groups of state and/or event handlers.
  • Relatedly, class components need to be replaced with function components and hooks since this will often enable us to remove the use of recompose.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions