You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 13, 2023. It is now read-only.
After switching to React Hot Loader v3 I'm now getting the following error:
React Hot Loader: this component is not accepted by Hot Loader.
Please check is it extracted as a top level class, a function or a variable.
Click below to reveal the source location:
ƒ GraphQL(props, context) {
...
Would you consider moving the GraphQL component outside of wrapWithApolloComponent and exporting it? There's really nothing functionally wrong with the code as it currently is, but this would help with hot module reloading, and clear up this annoying error message.
The text was updated successfully, but these errors were encountered:
Looking more closely at this it seems like this change is probably more painful than the benefit is worth. I'm going to close this for now and give it more thought. Sorry for the distraction.
After switching to React Hot Loader v3 I'm now getting the following error:
And the source is https://github.com/apollographql/react-apollo/blob/master/src/graphql.tsx#L101
I was getting plenty of errors like this with my own code too until I updated everything to export each intermediate HOC as described in the React Hot Loader FAQ here: https://github.com/gaearon/react-hot-loader/blob/master/docs/Troubleshooting.md#react-hot-loader-this-component-is-not-accepted-by-hot-loader
Would you consider moving the GraphQL component outside of wrapWithApolloComponent and exporting it? There's really nothing functionally wrong with the code as it currently is, but this would help with hot module reloading, and clear up this annoying error message.
The text was updated successfully, but these errors were encountered: