What are some limitations of things you shouldn’t do in the component’s render method?

Technology CommunityCategory: ReactWhat are some limitations of things you shouldn’t do in the component’s render method?
VietMX Staff asked 3 years ago

You cannot modify the component’s state (with setState), nor interact with the browser (do that in componentDidMount). Render should be a pure function.