vue-koa-demo icon indicating copy to clipboard operation
vue-koa-demo copied to clipboard

单元测试里面有国际化i18n 报错

Open mgbq opened this issue 6 years ago • 1 comments

大神你好,我参考了你的vue单元测试博客,你的demo没有使用i18n国际化,我的有使用,并且我是这样引入i18n的 import i18n from '@/lang' Vue.use(Element, { size: 'medium', // set element-ui default size i18n: (key, value) => i18n.t(key, value) })

可是它报错了 信息为 ERROR LOG: TypeError: undefined is not an object (evaluating 'i18n._t') 改成 import i18n from '@/lang' Vue.use(i18n) 也是报这个错,百忙中求解答

mgbq avatar May 25 '18 06:05 mgbq

并没有使用过i18n。。无法提供帮助诶,希望有类似的经验的人能帮忙

Molunerfinn avatar May 25 '18 07:05 Molunerfinn