forked from looker/custom_visualizations_v2
-
Notifications
You must be signed in to change notification settings - Fork 18
/
webpack.config.js
50 lines (47 loc) · 1.48 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
var path = require('path')
const UglifyJSPlugin = require('uglifyjs-webpack-plugin');
var webpackConfig = {
mode: 'production',
entry: {
advanced_table: './src/examples/advanced_table/advanced_table.js',
v1_common: './src/common/common-entry.js',
hello_world: './src/examples/hello_world/hello_world.js',
hello_world_react: './src/examples/hello_world_react/hello_world_react.js',
sankey: './src/examples/sankey/sankey.ts',
liquid_fill_gauge: './src/examples/liquid_fill_gauge/liquid_fill_gauge.ts',
sunburst: './src/examples/sunburst/sunburst.ts',
collapsible_tree: './src/examples/collapsible_tree/collapsible_tree.ts',
chord: './src/examples/chord/chord.ts',
treemap: './src/examples/treemap/treemap.ts',
subtotal: './src/examples/subtotal/subtotal.ts',
image_carousel: './src/examples/image_carousel/image_carousel.js'
},
output: {
filename: "[name].js",
path: path.join(__dirname, "dist"),
library: "[name]",
libraryTarget: "umd"
},
resolve: {
extensions: [".ts", ".js"]
},
plugins: [
new UglifyJSPlugin()
],
module: {
rules: [
{ test: /\.js$/, loader: "babel-loader" },
{ test: /\.ts$/, loader: "ts-loader" },
{ test: /\.css$/, loader: [ 'to-string-loader', 'css-loader' ] }
]
},
stats: {
warningsFilter: /export.*liquidfillgauge.*was not found/
},
performance: {
hints: false,
maxEntrypointSize: 512000,
maxAssetSize: 512000
}
}
module.exports = webpackConfig