gQuery
gQuery copied to clipboard
codegen missing in version 0.5.0
With version 0.5.0 from npm I get the following error on npm run dev
or npm run build
:
error when starting dev server:
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './codegen' is not defined by "exports" in <project-dir>/node_modules/@leveluptuts/g-query/package.json imported from <project-dir>/vite.config.js.timestamp-1659433708313.mjs
at new NodeError (node:internal/errors:387:5)
at throwExportsNotFound (node:internal/modules/esm/resolve:439:9)
at packageExportsResolve (node:internal/modules/esm/resolve:718:3)
at packageResolve (node:internal/modules/esm/resolve:892:14)
at moduleResolve (node:internal/modules/esm/resolve:958:20)
at defaultResolve (node:internal/modules/esm/resolve:1173:11)
at nextResolve (node:internal/modules/esm/loader:173:28)
at ESMLoader.resolve (node:internal/modules/esm/loader:852:30)
at ESMLoader.getModuleJob (node:internal/modules/esm/loader:439:18)
at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:76:40)
Version 0.2.3 was working fine. Is there anything wrong with the new release or are configuration changes required to make it work?
I second this....neither is vite:{} allowed. config.kit.vite has been removed — use vite.config.js instead
@bitnosis sure, but that config part can be moved manually to vite.config.js
@stolinski maybe this is a problem with npm and it works with pnpm?
@inta you found a solution for this?, I try with yarn and pnmp
No, I'm still on version 0.2.3 and thinking about how I can go on with GraphQL on SvelteKit.
Take a look at this client: GraphQL Zeus, generates a typed client from your schema, it works for me. Good Luck!
Thanks, I'll have a look and see how it can work together with Hasura (that's what I use as backend for GraphQL).
Still seems to be a problem... ... Package subpath './codegen' is not defined by "exports" ... was using npm.