-
Notifications
You must be signed in to change notification settings - Fork 0
/
_webpack.config.js
50 lines (50 loc) · 1.28 KB
/
_webpack.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
// const path = require('path')
// const {
// CleanWebpackPlugin
// } = require('clean-webpack-plugin')
// const UglifyJsPlugin = require('uglifyjs-webpack-plugin')
// const HtmlWebpackPlugin = require('html-webpack-plugin');
//
// module.exports = {
// mode: 'development',
// entry: './src/main.js',
// output: {
// path: path.resolve(__dirname, 'dist'),
// filename: 'gobang.min.js'
// // libraryTarget: 'umd',
// // library: 'gobang'
// },
// plugins: [
// new CleanWebpackPlugin(),
// new HtmlWebpackPlugin({
// // chunks: ['gobang.min.js'],
// filename: 'index.html',
// template: 'index.html'
// }),
// new UglifyJsPlugin()
// ],
// devtool: 'inline-source-map',
// devServer: {
// // 每次构建时候自动打开浏览器并访问网址
// // open: true,
// // 开启热更新
// // hot: true,
// contentBase: './dist'
// // port: "8080",
// // host: "localhost",
// // inline: true,
// },
// module: {
// rules: [{
// test: /\.js$/,
// // include: path.resolve(__dirname , 'src'),
// exclude: /node_modules/,
// use: ['babel-loader']
// },
// {
// test: /\.css$/,
// use: ['style-loader', 'css-loader']
// }
// ]
// }
// }