Closed yantakus closed 5 years ago
Was this package tested with non-SSR apps? I tried this one as a drop-in replacement for apollo-cache-persist, but I get the following error:
apollo-cache-persist
ReferenceError: process is not defined Module../node_modules/graphql/jsutils/instanceOf.mjs node_modules/graphql/jsutils/instanceOf.mjs:1 > 1 | export default process && process.env.NODE_ENV !== 'production' ? // eslint-disable-next-line no-shadow 2 | function instanceOf(value, constructor) { 3 | if (value instanceof constructor) { 4 | return true;
Looks like some server code runs in browser and, of course, breaks the app.
The issue is hard-to-debug, as the above error is the only useful in the stack, all the other point to webpack sources.
Any ideas?
I fixed the issue by upgrading graphql from 0.13.2 to the latest version (14.2.1 ATM). Seems to be a fixed bug in graphql package.
graphql
0.13.2
14.2.1
Was this package tested with non-SSR apps? I tried this one as a drop-in replacement for
apollo-cache-persist
, but I get the following error:Looks like some server code runs in browser and, of course, breaks the app.
The issue is hard-to-debug, as the above error is the only useful in the stack, all the other point to webpack sources.
Any ideas?