/
webpack.config.js
32 lines (31 loc) · 947 Bytes
/
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
const webpack = require('webpack');
var path = require('path');
var EncodingPlugin = require('webpack-encoding-plugin');
module.exports = {
entry: {
customIcons: "./js/customIcons.js",
},
output: {
libraryTarget: "var",
filename: "[name].js"
},
resolve: {
root: path.resolve("./"),
alias: {
"OfficeFabric": path.resolve( __dirname, "node_modules", "office-ui-fabric-react", "lib-amd"),
"react-dom": path.resolve( __dirname, "node_modules", "react-dom"),
"react": path.resolve( __dirname, "node_modules", "react"),
"jquery": path.resolve( __dirname, "node_modules", "jquery"),
}
},
plugins: [
new EncodingPlugin({
encoding: 'utf-8'
}),
new webpack.ProvidePlugin({
"$":"jquery",
"jQuery":"jquery",
"window.jQuery":"jquery"
}),
]
};