1
0
Fork 0
mirror of synced 2024-11-22 08:45:35 -05:00
ovpn-admin/frontend/webpack.config.js
Vitaliy Snurnitsin f180a9cc5a node 16.13
2022-01-29 02:22:08 +03:00

55 lines
1.1 KiB
JavaScript

// Generated using webpack-cli https://github.com/webpack/webpack-cli
const path = require('path');
const isProduction = process.env.NODE_ENV == 'production';
const config = {
entry: {
bundle: [
'./src/main.js',
],
style: [
'./src/style.js',
]
},
output: {
path: path.resolve(__dirname, './static/dist'),
publicPath: '/dist/',
filename: '[name].min.js'
},
plugins: [
],
module: {
rules: [
{
test: /\.css$/,
use: [
'vue-style-loader',
'css-loader'
],
},
{
test: /\.js$/,
exclude: /node_modules/,
loader: 'babel-loader',
options: {
presets: ['@babel/preset-env']
}
},
],
},
resolve: {
alias: {
'vue$': 'vue/dist/vue.esm.js'
},
extensions: ['*', '.js', '.vue', '.json']
},
};
module.exports = () => {
config.mode = 'production';
return config;
};