npm init

234 阅读1分钟

npm init过后

package name:      // 包名
version:          // 版本号1.0.0
description:       //描述
entry point:       // 入口文件(index.js)
test command:      //测试指令
git repository:    // git仓库
keywords:          // 关键字
author:           //作者
license(ISC):       // 协议 

npm init -y 所有的值都是默认值

然后就会生成package.json文件