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'm importing import UnpluginTypia from '@ryoppippi/unplugin-typia/vite' in vite.config.ts
nx serve gives
Failed to process project graph. Run "nx reset" to fix this. Please report the issue if you keep seeing it.
AggregateCreateNodesError: An error occurred while processing files for the @nx/vite/plugin plugin.
- apps/typia/vite.config.ts: Build failed with 1 error:
node_modules/esbuild/lib/main.js:1225:27: ERROR: [plugin: externalize-deps] "@ryoppippi/unplugin-typia/vite" resolved to an ESM file. ESM file cannot be loaded by `require`. See https://vitejs.dev/guide/troubleshooting.html#this-package-is-esm-only for more details.
at createNodesFromFiles (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/utils.js:58:15)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at Array.createNodesV2 (/Users/firfi/work/typia-nx/packages/vite/src/plugins/plugin.ts:57:14)
at LoadedNxPlugin.createNodes (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/internal-api.js:31:36)
at LoadedNxPlugin.createNodes.<computed> (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/internal-api.js:41:28)
at async Promise.all (index 1)
at processFilesAndCreateAndSerializeProjectGraph (/Users/firfi/work/typia-nx/node_modules/nx/src/daemon/server/project-graph-incremental-recomputation.js:148:43)
at Timeout._onTimeout (/Users/firfi/work/typia-nx/node_modules/nx/src/daemon/server/project-graph-incremental-recomputation.js:85:13)
import UnpluginTypia from '@ryoppippi/unplugin-typia/vite' in vite.config.ts of the app
Nx Report
it doesn't work because `import UnpluginTypia from '@ryoppippi/unplugin-typia/vite'` cannot be imported:➜ typia-nx git:(master) nx report NX Failed to process project graph. Run "nx reset" to fix this. Please report the issue if you keep seeing it.Pass --verbose to see the stacktraces.➜ typia-nx git:(master) nx reset NX Resetting the Nx cache and stopping the daemon. NX Successfully reset the Nx workspace.➜ typia-nx git:(master) nx report NX Failed to process project graph. Run "nx reset" to fix this. Please report the issue if you keep seeing it.Pass --verbose to see the stacktraces
### Failure Logs
```shell
Failed to process project graph. Run "nx reset" to fix this. Please report the issue if you keep seeing it.
AggregateCreateNodesError: An error occurred while processing files for the @nx/vite/plugin plugin.
- apps/typia/vite.config.ts: Build failed with 1 error:
node_modules/esbuild/lib/main.js:1225:27: ERROR: [plugin: externalize-deps] "@ryoppippi/unplugin-typia/vite" resolved to an ESM file. ESM file cannot be loaded by `require`. See https://vitejs.dev/guide/troubleshooting.html#this-package-is-esm-only for more details.
at createNodesFromFiles (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/utils.js:58:15)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at Array.createNodesV2 (/Users/firfi/work/typia-nx/packages/vite/src/plugins/plugin.ts:57:14)
at LoadedNxPlugin.createNodes (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/internal-api.js:31:36)
at LoadedNxPlugin.createNodes.<computed> (/Users/firfi/work/typia-nx/node_modules/nx/src/project-graph/plugins/internal-api.js:41:28)
at async Promise.all (index 1)
at processFilesAndCreateAndSerializeProjectGraph (/Users/firfi/work/typia-nx/node_modules/nx/src/daemon/server/project-graph-incremental-recomputation.js:148:43)
at Timeout._onTimeout (/Users/firfi/work/typia-nx/node_modules/nx/src/daemon/server/project-graph-incremental-recomputation.js:85:13)
### Package Manager Version
npm 10.2.4
### Operating System
- [X] macOS
- [ ] Linux
- [ ] Windows
- [ ] Other (Please specify)
### Additional Information
_No response_
The text was updated successfully, but these errors were encountered:
Current Behavior
I'm importing
import UnpluginTypia from '@ryoppippi/unplugin-typia/vite'
in vite.config.tsnx serve
giveshowever, a project created from https://vitejs.dev/guide/#scaffolding-your-first-vite-project (
npm create vite@latest
) imports the same plugin successfully and runs withnpm run dev
(ref: https://github.com/dearlordylord/typia-vite , don't mind README there, it's related to a runtime error in their plugin)Expected Behavior
It
serve
s without an error, likenpm run dev
runs in the official scaffold.GitHub Repo
https://github.com/dearlordylord/typia-nx
Steps to Reproduce
npx jsr add -D @ryoppippi/unplugin-typia
import UnpluginTypia from '@ryoppippi/unplugin-typia/vite'
in vite.config.ts of the appNx Report
The text was updated successfully, but these errors were encountered: