forked from wechat-miniprogram/weui-miniprogram
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mpflow.config.js
51 lines (50 loc) · 1.55 KB
/
mpflow.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
const TerserWebpackPlugin = require('terser-webpack-plugin')
module.exports = {
appId: 'wxe5f52902cf4de896',
projectName: '小程序自定义组件',
app: (mode) => (mode !== 'production' ? 'src/app' : undefined),
pages: (mode) => (mode !== 'production' ? undefined : ['src/components/index']),
sourceMap: (mode) => mode !== 'production',
compileType: 'miniprogram',
outputDir: 'miniprogram_dist',
plugins: ['@mpflow/plugin-babel', '@mpflow/plugin-typescript', '@mpflow/plugin-css'],
minimize: false,
configureWebpackChain: (config) => {
config.plugin('terser').use(TerserWebpackPlugin, [
{
terserOptions: {
compress: {
directives: false
}
}
}
])
},
settings: {
urlCheck: true,
es6: false,
postcss: false,
preloadBackgroundData: false,
minified: false,
newFeature: true,
coverView: true,
nodeModules: true,
autoAudits: false,
showShadowRootInWxmlPanel: true,
scopeDataCheck: false,
checkInvalidKey: true,
checkSiteMap: true,
uploadWithSourceMap: true,
compileHotReLoad: false,
babelSetting: {
ignore: [],
disablePlugins: [],
outputPath: ''
},
useIsolateContext: true,
useCompilerModule: false,
userConfirmedUseCompilerModuleSwitch: false,
compileWorklet: true,
minifyWXSS: false
}
}