react-form-with-constraints icon indicating copy to clipboard operation
react-form-with-constraints copied to clipboard

Crash "Can't perform a React state update on an unmounted component"

Open phong-steph opened this issue 5 years ago • 0 comments

react-dom.development.js?61bb:506 Warning: Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
    in Async (created by Coordonnees)
    in FieldFeedbacks (created by Coordonnees)
    in div (created by FormSectionGroup)
    in FormSectionGroup (created by Coordonnees)
    in Coordonnees (created by EtapePrincipale)
    in div (created by FormSection)
    in div (created by FormSection)
    in section (created by FormSection)
    in FormSection (created by EtapePrincipale)
    in fieldset (created by EtapePrincipale)
    in form (created by FormWithConstraints)
    in FormWithConstraints (created by EtapePrincipale)
    in div (created by EtapePrincipale)
    in EtapePrincipale (created by component)
    in component (created by Context.Consumer)

Context: the form (with hooks) performs a validation with Async, the validation is not done yet while the form is re-rendered (because the upper state has changed).

phong-steph avatar Jun 18 '19 13:06 phong-steph