-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.webpackrc.js
37 lines (34 loc) · 954 Bytes
/
.webpackrc.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
const path = require('path');
export default {
// entry: 'src/index.js',
entry:{
app: ['react-dev-utils/webpackHotDevClient?http://localhost:8080/', path.resolve(__dirname, 'src/index.js')]
},
extraBabelPlugins: [['import', { libraryName: 'antd', libraryDirectory: 'es', style: true }]],
env: {
development: {
extraBabelPlugins: ['dva-hmr'],
},
},
externals: {
'@antv/data-set': 'DataSet',
rollbar: 'rollbar',
},
alias: {
components: path.resolve(__dirname, 'src/components/'),
services: path.resolve(__dirname, 'src/services/'),
models: path.resolve(__dirname,'src/models'),
utils: path.resolve(__dirname,'src/utils')
},
ignoreMomentLocale: true,
theme: './src/theme.js',
html: {
template: './src/index.ejs',
},
lessLoaderOptions: {
javascriptEnabled: true,
},
disableDynamicImport: true,
outputPath:path.join(__dirname, 'web'),
publicPath: '/web',
};