C:\Users\admin9>npm install <package.json>
Ошибка в синтаксисе команды.
C:\Users\admin9>npm start
npm ERR! Missing script: "start"
npm ERR!
npm ERR! Did you mean one of these?
npm ERR! npm star # Mark your favorite packages
npm ERR! npm stars # View packages marked as favorites
npm ERR!
npm ERR! To see a list of scripts, run:
npm ERR! npm run
npm ERR! A complete log of this run can be found in: C:\Users\admin9\AppData\Local\npm-cache\_logs\2023-09-08T03_51_54_747Z-debug-0.log
C:\Users\admin9>npm starts
Unknown command: "starts"
Did you mean one of these?
npm star # Mark your favorite packages
npm stars # View packages marked as favorites
npm start # Start a package
To see a list of supported npm commands, run:
npm help
C:\Users\admin9>yarn start
yarn run v1.22.19
warning package.json: No license field
error Command "start" not found.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this commnd.
无法启动npm?
请帮帮我。连Yarn都不能开始
1条答案
按热度按时间afdcj2ne1#
检查项目
packege.json
文件,似乎没有启动脚本,因此您应该将"start":"node index.js"
添加到脚本中,并将index.js
更改为项目中主文件的名称