【文件属性】:
文件名称:webpack-tutorial:Webpack辅导
文件大小:8KB
文件格式:ZIP
更新时间:2021-04-29 19:39:40
JavaScript
#webpack教程
##安装webpack
npm install webpack -g
webpack --help
##初始化项目
创建项目
cd webpack
mkdir webpack-tutorial
cd webpack-tutorial
npm init -y
touch index.html
编辑index.html内容
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>webpack 教程</title>
</head>
<body>
</body>
</html>
##webpack配置
根目录创建webpack.config.js
cd webpack-tutorial
touch webpack.config.js
单页面应用里,项目通常会有一个入口(ent
【文件预览】:
webpack-tutorial-master
----.gitignore(578B)
----README.md(7KB)
----2.json(0B)
----LICENSE(1KB)
----bundle.js(1KB)
----package.json(725B)
----index.js(26B)
----3.json(0B)
----index.html(226B)
----webpack.config.js(630B)
----style()
--------app.css(27B)
----1.json(0B)