-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebpack.dev.config.js
More file actions
52 lines (49 loc) · 1.42 KB
/
webpack.dev.config.js
File metadata and controls
52 lines (49 loc) · 1.42 KB
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
44
45
46
47
48
49
50
51
52
'use strict';
var webpack = require('webpack');
var path = require('path');
module.exports = {
entry: [
'./src/index'
],
output: {
libraryTarget: 'umd',
sourcePrefix: ' ',
library: 'esp',
path: './dist/',
filename: 'esp-js-devtools.js'
},
debug: true,
devtool: 'inline-source-map',
module: {
loaders: [
{
test: /vendor\/.+\.(jsx|js)$/,
loader: 'imports?jQuery=jquery,$=jquery,this=>window'
},
{
loader: "babel-loader",
// Skip any files outside of your project's `src` directory
include: [
path.resolve(__dirname, "src"),
],
test: /\.jsx?$/,
query: {
presets: ['es2015', 'stage-0'],
plugins: ['transform-runtime', 'transform-decorators-legacy']
}
},
{
test: /\.(css|less)$/,
loader: 'style-loader!css-loader!less-loader'
},
{
test: /\.(otf|eot|png|svg|ttf|woff|woff2)(\?v=[0-9]\.[0-9]\.[0-9])?$/,
loader: 'file-loader?name=[path][name].[ext]?[hash]&mimetype=application/font-woff'
},
{
test: /\.html?$/,
loader: 'html-loader'
}
]
}
};