Skip to content

async-safe, static lifecycle hooks#6

Merged
acdlite merged 22 commits intoreactjs:masterfrom
bvaughn:static-lifecycle-methods
Jan 19, 2018
Merged

async-safe, static lifecycle hooks#6
acdlite merged 22 commits intoreactjs:masterfrom
bvaughn:static-lifecycle-methods

Conversation

@bvaughn
Copy link
Collaborator

@bvaughn bvaughn commented Dec 8, 2017

Note for React Native users: if you see a warning pointing to this page, this was most likely due to a mistake in our release process. This warning wasn’t supposed to fire until we finish writing the documentation for it, and wasn’t supposed to link to this page. We will either publish the documentation ASAP or revert this mistake in a patch release today (7th of March). We’re sorry for the disturbance.


If you reached this page from a warning saying "Legacy Context API has been detected within a strict mode tree.", you should visit this page for details on the stable Context API.


Replace error-prone render phase lifecycle hooks with static methods to make it easier to write async-compatible React components. Provide a clear migration path for legacy components to become async-ready.

Note that I plan to submit a related RFC soon for a new server-side lifecycle, componentDidServerRender, to offset any server-rendering functionality lost by deprecating componentWillMount.

Please leave comments below for high-level topics. For feedback on specific parts of this proposal, please leave inline comments (on the markdown file).

View proposal with formatting

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.