小编Tim*_*123的帖子

为什么我在使用 npx 时出现错误?

每次当我运行任何 npx 命令时,它都会给我同样的错误。除非我运行:npx -v然后它给我版本:9.2.0

这是错误:

npm ERR! code ENOENT
npm ERR! syscall lstat
npm ERR! path E:\Development
npm ERR! errno -4058
npm ERR! enoent ENOENT: no such file or directory, lstat 'E:\Development'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Tim\AppData\Local\npm-cache\_logs\2023-01-02T20_03_57_627Z-debug-0.log
Run Code Online (Sandbox Code Playgroud)

我已经用 nvm 更新了 npm,但这并没有改变。

我想运行npx create-react-app myAppornpx create-electron-app myApp但每个命令都会给我同样的错误。有人可以帮助我消除这个错误吗?

npm create-react-app npx

9
推荐指数
2
解决办法
9372
查看次数

标签 统计

create-react-app ×1

npm ×1

npx ×1