Skip to content

Updates for unsafe lifecycles -> Package will break in React 17.0 #14

Description

@adback03

In React 16.3, aliases were introduced for unsafe lifecycles:

  • UNSAFE_componentWillMount
  • UNSAFE_componentWillReceiveProps
  • UNSAFE_componentWillUpdate

In the most recent version of React (16.9.*), console warnings highlight that starting with React 17.0, if you are not using the UNSAFE aliases, the component will not work.

image

Would you be able to publish a new package with the unsafe aliases in place?

cd your_project
npx react-codemod rename-unsafe-lifecycles

More information can be found here: https://reactjs.org/blog/2018/03/27/update-on-async-rendering.html

Activity

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

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions