webpack安装
2019-11-18 本文已影响0人
小蜗牛的碎碎步
创建项目文件夹
- 命令
mkdir my-webpack
cd my-webpack
npm init -y //所有需要确认项都默认为yes
- 结果
{
"name": "my-webpack",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [],
"author": "",
"license": "ISC"
}
安装webpack、webpack-cli
cnpm install webpack webpack-cli --save-dev
webpack -v //检验是否安装成功