forked from akeneo/pim-community-dev
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwebpack-test.config.js
30 lines (27 loc) · 899 Bytes
/
webpack-test.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
/* eslint-env es6 */
const path = require('path');
const HtmlWebpackInlineSourcePlugin = require('html-webpack-inline-source-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const prodConfig = require('./webpack.config.js');
const config = Object.assign({}, prodConfig, {
entry: [
'babel-polyfill',
path.resolve(__dirname, './tests/front/common/templates/index.js')
],
output: {
path: path.resolve('./web/test_dist/'),
publicPath: '/dist/',
filename: '[name].min.js',
chunkFilename: '[name].bundle.js'
}
});
config.plugins.push(new HtmlWebpackInlineSourcePlugin());
config.plugins.push(
new HtmlWebpackPlugin({
inject: 'head',
template: path.resolve(__dirname, './tests/front/common/templates/index.html'),
minify: {},
inlineSource: '.(js)$'
})
);
module.exports = config;