2021-09-22 10:05:00 +02:00
|
|
|
const path = require('path');
|
|
|
|
const isProduction = process.env.NODE_ENV === 'production';
|
|
|
|
|
|
|
|
module.exports = {
|
2022-09-09 10:28:26 +03:00
|
|
|
devtool: isProduction ? 'source-map' : 'eval-source-map',
|
2021-09-22 10:05:00 +02:00
|
|
|
mode: isProduction ? 'production' : 'development',
|
|
|
|
target: 'web',
|
|
|
|
entry: {
|
2021-09-22 15:49:24 +02:00
|
|
|
'myaccount-payments': path.resolve('./resources/js/myaccount-payments.js'),
|
2021-09-22 10:05:00 +02:00
|
|
|
},
|
|
|
|
output: {
|
|
|
|
path: path.resolve(__dirname, 'assets/'),
|
|
|
|
filename: 'js/[name].js',
|
|
|
|
},
|
|
|
|
module: {
|
|
|
|
rules: [{
|
|
|
|
test: /\.js?$/,
|
|
|
|
exclude: /node_modules/,
|
|
|
|
loader: 'babel-loader',
|
2021-09-22 15:49:24 +02:00
|
|
|
}]
|
2021-09-22 10:05:00 +02:00
|
|
|
}
|
|
|
|
};
|