create-next-app'不公认为内部或外部命令,可操作程序或批处理文件

发布于 2025-01-20 07:19:21 字数 269 浏览 2 评论 0 原文

我正在尝试使用 npx create-next-app nextjs-blog 安装下一个应用程序,但我不断收到此错误;

“create-next-app”未被识别为内部或外部命令, 可运行的程序或批处理文件。

我从周五开始就被困住了,还没有得到合适的解决方案,请帮忙。 我刚刚开始学习 next js Nd,我不确定为什么我会一遍又一遍地收到此错误。

我已经卸载并重新安装了我的节点,错误仍然存​​在

I'm trying to install next app with npx create-next-app nextjs-blog and i keep getting this error;

'create-next-app' is not recognized as an internal or external command,
operable program or batch file.

I've been stucked since friday and haven't gotten w befitting solution, pls help out.
I just started learning next js Nd I'm not sure why I'm getting this error over and over.

I've uninstalled and reinstalled my node the error still persist

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

追我者格杀勿论 2025-01-27 07:19:21

我在 Windows 10 上的问题是由于某种原因我的环境变量(特别是路径用户变量)重复了许多变量,超出了最大 4096 限制,而没有告诉我。我手动删除了一堆重复项,然后保存它,没有达到最大限制错误。然后我刷新了环境变量,关闭了所有终端,然后 create-next-app 开始工作。

My issue on windows 10 was for some reason my environment variables, specifically the path user variable, had gotten many variables duplicated, exceeing the max 4096 limit without telling me. I manually deleted a bunch of duplicates and then saving it worked without the max limit reached error. I then refreshed my environment variables, closed all terminals, and then create-next-app worked.

许你一世情深 2025-01-27 07:19:21

首先安装这个:

npm i -g create-next-app

然后:

create-next-app

First Install This:

npm i -g create-next-app

Then:

create-next-app
萌无敌 2025-01-27 07:19:21

来自 NextJs 文档:

npx create-next-app@latest.

From NextJs docs:

npx create-next-app@latest.
情绪失控 2025-01-27 07:19:21

命令 :

纱线创建Next-App

参考:

command :

yarn create next-app

reference : https://nextjs.org/docs/api-reference/create-next-app

つ可否回来 2025-01-27 07:19:21

首先我们需要安装 npm i -g create-next-app。

在系统中添加路径变量。
C:\Users{用户名}\AppData\Roaming\npm

First we need to install npm i -g create-next-app.

Add the path variable in system.
C:\Users{User_name}\AppData\Roaming\npm

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文