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
I am trying to use Apollo extension in a React application created with Vite.
I create apollo.config.js at the root folder, following the intructions, like this : module.exports = { client: { service: { name: "my-graphql-app", url: "http://localhost:4000/graphql", }, }, };
But i get the error "'module' is not defined." , since it is not an E6 Module.
Therefore Apollo extension cannot find the file, getting this error from the extension : Service stats could not be loaded. This may be because you're missing an apollo.config.js file or it is misconfigured.
How could I convert it to an E6 Module, or how should i create the config file to be able to use it in a React App using Vite?
If I use CreateReactApp to create the React app, then there is no issue.
The text was updated successfully, but these errors were encountered:
I am trying to use Apollo extension in a React application created with Vite.
I create
apollo.config.js
at the root folder, following the intructions, like this :module.exports = { client: { service: { name: "my-graphql-app", url: "http://localhost:4000/graphql", }, }, };
But i get the error "'module' is not defined." , since it is not an E6 Module.
Therefore Apollo extension cannot find the file, getting this error from the extension :
Service stats could not be loaded. This may be because you're missing an apollo.config.js file or it is misconfigured.
How could I convert it to an E6 Module, or how should i create the config file to be able to use it in a React App using Vite?
If I use CreateReactApp to create the React app, then there is no issue.
The text was updated successfully, but these errors were encountered: