ss
gaobaoming
2018-10-31 c525efd1f7151f145c10b3cf9015c1d53577b973
commit | author | age
2f5b9b 1 /**
B 2  * Created by Jacky.gao on 2016/5/17.
3  */
4 var webpack = require('webpack');
5 module.exports = {
6     entry: {
7         designer:'./src/index.js',
8         preview:'./src/preview.js',
9         searchform: './src/form/index.js',
10         common:'./src/common.js'
11     },
12     output: {
13         path: '../report-console/src/main/resources/report-asserts/js',
14         filename: '[name].bundle.js'
15     },
16     module: {
17         loaders: [
18             {
19                 test: /\.(jsx|js)?$/,
20                 exclude: /(node_modules|bower_components)/,
21                 loader: 'babel',
22                 query: {
23                     presets: ['react', 'es2015'],
24                     compact:true
25                 }
26             },
27             {
28                 test: /\.css$/,
29                 loader: "style-loader!css-loader"
30             },
31             {
32                 test: /\.json$/,
33                 loader: 'json-loader'
34             },
35             {
36                 test   : /\.woff/,
37                 loader : 'url?prefix=font/&limit=10000&mimetype=application/font-woff'
38             }, {
39                 test   : /\.(ttf|png)/,
40                 loader : 'file?prefix=font/'
41             }, {
42                 test   : /\.eot/,
43                 loader : 'file?prefix=font/'
44             }, {
45                 test   : /\.svg/,
46                 loader : 'file?prefix=font/'
47             }
48         ]
49     }
50 };