Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Avoid using return value from ReactDOM.render() #125

Open
wants to merge 1 commit into
base: next
Choose a base branch
from
Open

Avoid using return value from ReactDOM.render() #125

wants to merge 1 commit into from

Conversation

elementsweb
Copy link

According to the ReactDOM documentation at https://facebook.github.io/react/docs/react-dom.html#render, we should avoid using the return value from ReactDOM.render():

ReactDOM.render() currently returns a reference to the root ReactComponent instance. However, using this return value is legacy and should be avoided because future versions of React may render components asynchronously in some cases. If you need a reference to the root ReactComponent instance, the preferred solution is to attach a callback ref to the root element.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant