yarn build/start import @apollo/client/core/core.cjs.js?
See original GitHub issueEnvironment
- Operating System:
Darwin
- Node Version:
v16.13.0
- Nuxt Version:
3.0.0-27276275.abfbd2f
- Package Manager:
yarn@1.22.15
- Bundler:
Vite
- User Config:
build
- Runtime Modules:
-
- Build Modules:
-
Describe the bug
yarn build yarn start
Reproduction
https://github.com/productdevbook/productdevbook.com
Additional context
No response
Logs
➜ productdevbook.com git:(main) yarn start
yarn run v1.22.15
$ node .output/server/index.mjs
Listening on http://localhost:3000
Directory import '/Users/productdevbook/Documents/GitHub/productdevbook.com/.output/server/node_modules/@apollo/client/core' is not supported resolving ES modules imported from /Users/productdevbook/Documents/GitHub/productdevbook.com/.output/server/chunks/app/server.mjs
Did you mean to import @apollo/client/core/core.cjs.js?
at new NodeError (node:internal/errors:371:5)
at finalizeResolution (node:internal/modules/esm/resolve:412:17)
at moduleResolve (node:internal/modules/esm/resolve:932:10)
at defaultResolve (node:internal/modules/esm/resolve:1044:11)
at ESMLoader.resolve (node:internal/modules/esm/loader:422:30)
at ESMLoader.getModuleJob (node:internal/modules/esm/loader:222:40)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:76:40)
at link (node:internal/modules/esm/module_job:75:36)
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:14 (9 by maintainers)
Top Results From Across the Web
yarn build/start import @apollo/client/core/core.cjs.js? #9048
js extension if you are using core.cjs.js Example import ApolloClientCore from '@apollo/client/core/core.cjs.js'; => import ApolloClientCore ...
Read more >Cannot run next.js app. It shows weird error - Stack Overflow
It's possible your Next configuration file isn't included and some values (environment variables for example) aren't readable for your project.
Read more >rollup.js
This allows you to build on top of existing tools and modules without adding extra dependencies or bloating the size of your project....
Read more >Building for Production - Vite
JS -imported asset URLs, CSS url() references, and asset references in your ... be called at buildStart for build watch mode to work...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@danielroe https://github.com/apollographql/apollo-client/issues/9048#issuecomment-979014870
Hi, I have the same problem, have you solved it?