-
Notifications
You must be signed in to change notification settings - Fork 40
/
webpack.config.js
67 lines (61 loc) · 1.58 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
const webpack = require('webpack');
const package = require('./package.json');
const banner =
" Vuedals plugin v" + package.version + "\n" +
"\n" +
" Multiple event based modal windows, with a single component\n" +
"\n" +
" This is a plugin to open any number of modal windows without having to attach them to the DOM\n" +
" @author "+ package.author.name +" <"+ package.author.email +">\n" +
" "+ package.homepage +"\n" +
" Released under the MIT License.";
module.exports = {
entry: './src/main.js',
output: {
path: './dist/',
filename: 'vuedals.js',
library: 'Vuedals',
libraryTarget: 'umd',
umdNamedDefine: true
},
resolve: {
extensions: ['', '.js', '.vue']
},
module: {
loaders: [
{
test: /\.js$/,
loader: 'babel',
include: __dirname,
exclude: /node_modules/
},
{
test: /\.vue$/,
loader: 'vue'
},
{
test: /\.css$/,
loader: 'style!css'
}
]
},
resolve: {
alias: {
'vue$': 'vue/dist/vue.common.js'
}
},
plugins: [
new webpack.BannerPlugin(banner),
new webpack.optimize.UglifyJsPlugin({
minimize: false,
sourceMap: false,
mangle: false,
compress: {
warnings: false
},
output: {
comments: true
}
})
]
};