You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
567 B
29 lines
567 B
4 years ago
|
const IS_PROD = ['production', 'prod'].includes(process.env.NODE_ENV)
|
||
|
|
||
|
const plugins = []
|
||
|
if (IS_PROD) {
|
||
|
plugins.push('transform-remove-console')
|
||
|
}
|
||
|
|
||
|
// lazy load ant-design-vue
|
||
|
// if your use import on Demand, Use this code
|
||
|
plugins.push(['import', {
|
||
|
'libraryName': 'ant-design-vue',
|
||
|
'libraryDirectory': 'es',
|
||
|
'style': true // `style: true` 会加载 less 文件
|
||
|
}])
|
||
|
|
||
|
module.exports = {
|
||
|
presets: [
|
||
|
'@vue/cli-plugin-babel/preset',
|
||
|
[
|
||
|
'@babel/preset-env',
|
||
|
{
|
||
|
'useBuiltIns': 'entry',
|
||
|
'corejs': 3
|
||
|
}
|
||
|
]
|
||
|
],
|
||
|
plugins
|
||
|
}
|