赞
踩
报错:
原来写法:
export const loadView = (view) => {
return () => import(`@/views/${view}`)
}
修改为:
export const loadView = (view) => {
return (resolve) => require([`@/views/${view}`], resolve)
}
原因:webpack 版本问题,webpack4中动态import不支持变量方式
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。