1 Star 1 Fork 425

lghshiyan/xm-select

forked from maplemei/xm-select 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
webpack.config.js 1.05 KB
一键复制 编辑 原始数据 按行查看 历史
maplemei 提交于 2019-04-30 11:07 . init
const path = require('path');
const HtmlWebpackPlugin = require('html-webpack-plugin');
module.exports = {
entry: "./src/index.js",
output: {
path: path.resolve(__dirname, 'dist'),
filename: "xm-select.js"
},
module: {
rules: [{
test: /\.css$/,
use: 'css-loader'
}, {
test: /\.less$/,
exclude: /node_modules/,
loader: 'style-loader!css-loader!less-loader'
}, {
test: /\.m?js$/,
exclude: /(node_modules|bower_components)/,
use: {
loader: 'babel-loader',
options: {
presets: ['@babel/preset-env']
}
}
}]
},
resolve: {
alias: {
'@': path.resolve(__dirname, "src"),
'components': path.resolve(__dirname, "src/components"),
'style': path.resolve(__dirname, "src/style"),
}
},
plugins: [
new HtmlWebpackPlugin({
template: './src/index.ejs',
minify: {
collapseWhitespace: true
}
}),
],
devServer: {
contentBase: path.join(__dirname, "./dist"),
compress: true,
host: '0.0.0.0',
port: 9000,
open: true,
hot: true,
}
};
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/lghshiyan/xm-select.git
git@gitee.com:lghshiyan/xm-select.git
lghshiyan
xm-select
xm-select
master

搜索帮助