Skip to content

warning message recommends using soon deprecated lifecycle methods #12748

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
iliran11 opened this issue May 5, 2018 · 6 comments
Closed

warning message recommends using soon deprecated lifecycle methods #12748

iliran11 opened this issue May 5, 2018 · 6 comments

Comments

@iliran11
Copy link

iliran11 commented May 5, 2018

Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?

React 16.3.1

What is the current behavior?
Warning message recommends using soon to-be deprecated lifecycle method - componentWillMount

Warning Content:
Warning: Cannot update during an existing state transition (such as within renderor another component's constructor). Render methods should be a pure function of props and state; constructor side-effects are an anti-pattern, but can be moved tocomponentWillMount.
What is the expected behavior?
warning messages should be inline with deprecation plans.

@gaearon
Copy link
Collaborator

gaearon commented May 5, 2018

Want to send a fix?

@iliran11
Copy link
Author

iliran11 commented May 6, 2018

Yes, i will take this issue and send a PR.

@asiniy
Copy link

asiniy commented Jun 6, 2018

@gaearon it looks like @iliran11 sent a fix, but it's not so detailed, so I'm picking this one. Will send a PR in a few days.

@iliran11
Copy link
Author

iliran11 commented Jun 6, 2018

@asiniy i'm on it. will send a PR in few minutes

@asiniy
Copy link

asiniy commented Jun 6, 2018

:(

@gaearon
Copy link
Collaborator

gaearon commented Aug 2, 2018

This was fixed in #13169.

@gaearon gaearon closed this as completed Aug 2, 2018
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

3 participants