1
NPM init 命令帮助我们快速初始化 package.JSON 文件
NPM init -y 来超速初始化
[email protected] 提供了 npx 命令将安装运行两个步骤合二为一,
例如: 直接执行 npx think-cli 会先安装 think-cli 模块然后执行 think-cli 命令, 最终完成脚手架的启动.
在 [email protected] 里增加了 NPM init <initializer > 这种操作, 简单来说就是你执行 NPM init thinkjs 的话 NPM 会补全模块名为 create-thinkjs 并执行 npx create-thinkjs.
- NPM init thinkjs
- # same as
- npx create-thinkjs
来源: http://www.bubuko.com/infodetail-3093788.html