cunzaizhuyi / qwik-demo

https://qwikdemo.netlify.app/
2 stars 0 forks source link

window下使用pnpm下载项目,然后 npm run build 报错 #1

Open M76chao opened 1 year ago

M76chao commented 1 year ago

我是在B站看到你视频过来的,想运行一下,却失败了,我刚在他们源仓库看了一下,确实有人跟我一样的问题,不是pnpm 的问题,好像是qwik本身的问题。

window11 nodejs18.12 pnpm7.14

使用命令npm create qwik@latast 新建的项目,然后cd进去使用pnpm下载文档。

然后 pnpm run qwik add ,选择 netlify-edge。

然后运行 npm run build报错:

`error during build: Error [PLUGIN_ERROR]: Only URLs with a scheme in: file, data are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'd:'
at new NodeError (node:internal/errors:393:5) at throwIfUnsupportedURLScheme (node:internal/modules/esm/resolve:1026:11) at defaultResolve (node:internal/modules/esm/resolve:1106:3) at nextResolve (node:internal/modules/esm/loader:163:28) at ESMLoader.resolve (node:internal/modules/esm/loader:841:30) at ESMLoader.getModuleJob (node:internal/modules/esm/loader:424:18) at ESMLoader.import (node:internal/modules/esm/loader:525:22) at importModuleDynamically (node:internal/modules/esm/translators:110:35) at importModuleDynamicallyCallback (node:internal/process/esm_loader:35:14) at mainThread (file:///D:/myDemo/qwik-app/node_modules/.pnpm/@builder.io+qwik-city@0.0.118/node_modules/@builder.io/qwik-city/static/node.mjs:359:43)

 ELIFECYCLE  Command failed with exit code 1. `

cunzaizhuyi commented 1 year ago

尝试着修一下,给qwik提个pr