Reputation: 734
Can anyone explain why when running gatsby develop
the Child component’s lifecycle method componentWillReceiveProps
is ignored and it is re-mounted with every new change - whereas when building the static version of the app, the Child's componentWillReceiveProps
lifecycle method is executed correctly.
See attached ‘dev’ and build
gifs, or checkout the source.
Dev
Build
Upvotes: 0
Views: 139
Reputation: 734
Thanks to @Nenu, I discovered that the issue is elsewhere. Using the example code in a fresh gatsby project worked as expected.
Upvotes: 0