VUE-cli 兼容 IE
main.js
import 'babel-polyfill'
//
webpack.base.conf.js
//
webpack.base.conf.js
entry: {
app: ["babel-polyfill", "./src/main.js"]
},
&&
光加上 ["babel-polyfill", "./src/main.js"] 还是不够的,需要在rules的 include 里面都添加一遍
module:{
rules: [
{
test: /\.js$/,
loader: 'babel-loader',
include: [
resolve('src'),
resolve('test'),
resolve('node_modules/webpack-dev-server/client'),
resolve('/node_modules/element-ui/src'),
resolve('/node_modules/element-ui/pachages'),
resolve('/node_modules/_element-ui@2.3.4@_element-ui/src'),
resolve('/node_modules/_element-ui@2.3.4@_element-ui/pachages'),
resolve('/node_modules/easyscroll/src'),
resolve('/node_modules/_easyscroll@1.0.1@easyscroll/src')
]
}
]
}
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步