1 | var webpack = require('webpack');
|
2 | var webpackConfig = require('./webpack.config.js');
|
3 | var path = require('path');
|
4 | var Clean = require('clean-webpack-plugin');
|
5 |
|
6 | module.exports = {
|
7 | cache: true,
|
8 | entry: webpackConfig.entry,
|
9 | output: webpackConfig.output,
|
10 | resolve: webpackConfig.resolve,
|
11 | module: {
|
12 | rules: [
|
13 | {
|
14 | test: /\.js$/,
|
15 | include: path.join(__dirname, 'src'),
|
16 | exclude: /tablefilter\/node_modules/,
|
17 | loader: 'isparta-loader'
|
18 | }
|
19 | ]
|
20 |
|
21 |
|
22 | },
|
23 | devtool: 'source-map',
|
24 | plugins: [
|
25 | new Clean(['dist']),
|
26 | new webpack.LoaderOptionsPlugin({
|
27 | debug: true,
|
28 | options: {
|
29 | isparta: {
|
30 | embedSource: true,
|
31 | noAutoWrap: true,
|
32 | babel: {
|
33 | compact: false,
|
34 | presets: ['es2015'],
|
35 | plugins: [['transform-es2015-classes', {loose: true}]]
|
36 | }
|
37 | }
|
38 | }
|
39 | })
|
40 | ]
|
41 | };
|