metamn / inu-v2-b

A photo portfolio theme with React and WordPress
http://inu.ro
4 stars 2 forks source link

Fix the randomly appearing console warning #28

Open metamn opened 5 years ago

metamn commented 5 years ago

I'm getting randomly this warning in the browser console. Sometimes it shows up, sometimes not, without touching the code.

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 ProgressiveImage (at ImageResponsive.js:204)
    in ImageResponsive (at PostFeaturedImage.js:188)
    in div (created by Context.Consumer)
    in StyledComponent (created by styled.div)
    in styled.div (at PostFeaturedImage.js:254)
    in PostFeaturedImage (at Post.js:73)
    in article (created by Article)
    in Article (created by Context.Consumer)
    in StyledComponent (created by Styled(Article))
    in Styled(Article) (at Post.js:72)
    in Post (at Slides.js:73)
    in div (created by Context.Consumer)
    in StyledComponent (created by styled.div)
    in styled.div (at Slide.js:84)
    in Slide (at Slides.js:72)
    in div (created by Context.Consumer)
    in StyledComponent (created by styled.div)
    in styled.div (at Slides.js:79)
    in ForwardRef (at Slider.js:254)
    in section (created by Section)
    in Section (created by Context.Consumer)
    in StyledComponent (created by Styled(Styled(Section)))
    in Styled(Styled(Section)) (at Slider.js:248)
    in Slider (at Content.js:206)
    in DisplayContent (at Content.js:228) wpThemeErrorOverlay.js:233:319716
    e wpThemeErrorOverlay.js:233
    React 5
    ProgressiveImage dist.js:187
    ProgressiveImage dist.js:176
devloco commented 5 years ago

This should go away after you update to the latest create-react-wptheme.

The updating instructions are here: Updating Existing Themes