forked from rstgroup/react-components-form
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack-prod.config.js
38 lines (37 loc) · 1.01 KB
/
webpack-prod.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
31
32
33
34
35
36
37
38
var webpack = require('webpack');
var path = require('path');
module.exports = {
entry: {
main: "./src/index.js",
Bootstrap: "./src/components/styled/Bootstrap.js",
Separate: "./src/components/separate/index.js",
AutocompleteField: "./src/components/AutocompleteField.js"
},
output: {
path: path.join(__dirname, ''),
filename: "[name].js",
libraryTarget: "umd"
},
resolve: {
extensions: ['.js', '.jsx']
},
module: {
loaders: [
{
test: /\.css$/,
loader: 'style-loader!css-loader?modules=true&localIdentName=[name]__[local]___[hash:base64:5]'
},
{
test: /.jsx?$/,
loader: 'babel-loader',
exclude: /node_modules/,
query: {
presets: ['es2015', 'stage-0', 'es2017', 'react']
}
}
]
},
devServer: {
historyApiFallback: true
}
};