Skip to content
This repository was archived by the owner on Dec 31, 2020. It is now read-only.
This repository was archived by the owner on Dec 31, 2020. It is now read-only.

Warning: forceUpdate(...): Can only update a mounting component #149

@louy

Description

@louy

With server-side rendering, I'm getting this warning a lot:

Warning: forceUpdate(...): Can only update a mounting component. This usually means you called forceUpdate() outside componentWillMount() on the server. This is a no-op. Please check the code for the LoginPage component.

I think the issue is that observer starts listening for changes on componentWillMount and stops on componentWillUnmount. However, react-dom/server never calls componentWillUnmount as the component is never mounted in the first place.

I'm not sure how to solve this to be honest, but the way it works right now probably has a lot of memory leaks as well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions