-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebpack-config.js
More file actions
27 lines (23 loc) · 785 Bytes
/
Copy pathwebpack-config.js
File metadata and controls
27 lines (23 loc) · 785 Bytes
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
var path = require ('path');
var webpack = require ('webpack');
module.exports = {
resolve: {
extensions: ['*', '.js', '.jsx', '.json', '.ts', '.tsx']
},
entry : path.resolve(__dirname,'./src/index.js'),
devtool: 'source-map',
output : {
path: path.resolve(__dirname+'/build'),
filename : 'bundle.js',
publicPath:'/'
},
module:{
loaders:[
{test: /\.js$/,exclude:/node_modules/,use: ['babel-loader']},
{ test: /(\.css)$/, loaders: ['style', 'css'] },
{ test: /(\.png)$/, loader: 'url?limit=10000' },
{ test: /(\.jpg)$/, loader: 'url?limit=10000' },
{ test: /(\.jpeg)$/, loader: 'url?limit=10000' }
],
}
};