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
|
var path = require('path');
var webpack = require('webpack');
var copyWebpack = require('./config/copy-webpack');
var aliases = require('./config/alias-webpack');
module.exports = {
entry: {
app: './app/js/index.js',
sandbox: './app/js/sandbox.js'
},
node: { fs: 'empty' },
output: {
path: path.join(__dirname, 'dist'),
filename: '[name].js',
publicPath: '/assets/'
},
resolve: {
alias: aliases,
extensions: ['', '.js']
},
module: {
loaders: [
{
test: /\.js$/,
exclude: /(node_modules|bower_components)/,
loader: 'babel',
query: { presets: ['es2015']}
}
]
},
plugins: [copyWebpack]
}
|