Uncaught (in promise) TypeError: l.then is not a function

vue3通过yarn打包

  • 打包之前跳转没有问题
  • 打包之后 导航栏点击报错Uncaught (in promise) TypeError: l.then is not a function

Uncaught (in promise) TypeError: l.then is not a function

Uncaught (in promise) TypeError: l.then is not a function

我是哈哈怪,每天笑哈哈. go/php开发, 业余喜欢写技术文章,欢迎关注我的个人网站 公众号:哈哈怪玩编程
讨论数量: 5
错误:
{ path: '/401', name: '401', component: import('@/views/errors/401.vue') }

正确:
{ path: '/401', name: '401', component: () => import('@/views/errors/401.vue') }

吐槽: 官方的锅 :unamused: 要么都不行,要么都行,才是一个好的项目。

1年前 评论
哈哈怪 (楼主) 1年前

route/index.js就是这样用的呀

file

file

1年前 评论
lyxxxh 1年前
哈哈怪 (作者) (楼主) 1年前

讨论应以学习和精进为目的。请勿发布不友善或者负能量的内容,与人为善,比聪明更重要!