mirror of
https://github.com/Luzifer/password.git
synced 2024-11-10 02:10:00 +00:00
44 lines
803 B
JavaScript
44 lines
803 B
JavaScript
|
const path = require('path')
|
||
|
const webpack = require('webpack')
|
||
|
|
||
|
module.exports = {
|
||
|
entry: './src/index.js',
|
||
|
|
||
|
output: {
|
||
|
filename: 'bundle.js',
|
||
|
path: path.resolve(__dirname, '../frontend/assets'),
|
||
|
publicPath: "assets/"
|
||
|
},
|
||
|
|
||
|
module: {
|
||
|
rules: [{
|
||
|
test: /\.m?js$/,
|
||
|
exclude: /(node_modules|bower_components)/,
|
||
|
use: {
|
||
|
loader: 'babel-loader',
|
||
|
options: {
|
||
|
presets: ['@babel/preset-env']
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
{
|
||
|
test: /\.css$/,
|
||
|
use: ['style-loader', 'css-loader']
|
||
|
},
|
||
|
{
|
||
|
test: /\.(woff|woff2|eot|ttf|otf|svg)$/,
|
||
|
use: [
|
||
|
'file-loader'
|
||
|
]
|
||
|
}
|
||
|
]
|
||
|
},
|
||
|
|
||
|
plugins: [
|
||
|
new webpack.ProvidePlugin({
|
||
|
'jQuery': 'jquery',
|
||
|
'$': 'jquery',
|
||
|
})
|
||
|
]
|
||
|
}
|