见elementUi操作, 在babelrc中将写入:
module.exports = {
presets: [
["@babel/preset-env", { "modules": false }] //注意: 此处要将官方的"es2015" 改为"@babel/preset-env"
],
plugins: [
[
"component",
{
"libraryName": "element-ui",
"styleLibraryName": "theme-chalk"
}
]
]
}