记录每次跳坑
二手翻译原文:NUXT 2.15.7不使用IE11。(脚本1002:语法错误) - 编程技术网 - Powered by Discuz!
二话不说直接上码
对于IE11中的开发构建,NUXT在nuxt.config.js中移动几个依赖关系:
isDev && isLegacy && 'ansi-regex', ({ isDev, isLegacy }) => isDev && isLegacy && 'strip-ansi' ] } }">
export default {
// ...
build: {
transpile: [
({ isDev, isLegacy }) => isDev && isLegacy && 'ansi-regex',
({ isDev, isLegacy }) => isDev && isLegacy && 'strip-ansi'
]
}
}
似乎WebPack的热中间件需要这些不再兼容ES5的软件包的版本。