forked from react-component/calendar
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.config.js
43 lines (39 loc) · 1.44 KB
/
webpack.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
39
40
41
42
43
var webpack = require("webpack");
var path = require('path');
module.exports = {
entry: {
'simple': ['./examples/simple.js'],
'disabled': ['./examples/disabled.js'],
'picker': ['./examples/picker.js'],
'theme': ['./examples/theme.js']
},
output: {
path: path.join(__dirname, 'build', 'examples'),
filename: '[name].js'
},
module: {
loaders: [
{test: /\.js$/, loader: 'jsx-loader'},
{test: /\.css/, loader: 'style!css'},
// Needed for the css-loader when [bootstrap-webpack](https://github.com/bline/bootstrap-webpack)
// loads bootstrap's css.
{ test: /\.woff(\?v=\d+\.\d+\.\d+)?$/, loader: "url?limit=10000&minetype=application/font-woff" },
{ test: /\.woff2(\?v=\d+\.\d+\.\d+)?$/, loader: "url?limit=10000&minetype=application/font-woff" },
{ test: /\.ttf(\?v=\d+\.\d+\.\d+)?$/, loader: "url?limit=10000&minetype=application/octet-stream" },
{ test: /\.eot(\?v=\d+\.\d+\.\d+)?$/, loader: "file" },
{ test: /\.svg(\?v=\d+\.\d+\.\d+)?$/, loader: "url?limit=10000&minetype=image/svg+xml"}
]
},
resolve: {
root: __dirname,
alias: {
'rc-calendar/assets/bootstrap.css': 'assets/bootstrap.css',
'rc-calendar/assets/classic.css': 'assets/classic.css',
'rc-calendar': 'index.js'
}
},
plugins: [
// ./robot is automatically detected as common module and extracted
new webpack.optimize.CommonsChunkPlugin("common.js")
]
};