mirror of https://github.com/ElemeFE/element
update element use vue-i18n@6.x and other i18n docs
parent
986c4a2127
commit
737885603f
|
@ -102,7 +102,7 @@ const i18n = new VueI18n({
|
|||
})
|
||||
|
||||
Vue.use(Element, {
|
||||
i18n: key => i18n.t(key)
|
||||
i18n: (key, value) => i18n.t(key. value)
|
||||
})
|
||||
|
||||
new Vue({ i18n }).$mount('#app')
|
||||
|
@ -138,7 +138,7 @@ const i18n = new VueI18n({
|
|||
messages, // set locale messages
|
||||
})
|
||||
|
||||
ElementLocale.i18n(key => i18n.t(key))
|
||||
ElementLocale.i18n((key, value) => i18n.t(key, value))
|
||||
```
|
||||
|
||||
## Import via CDN
|
||||
|
|
|
@ -114,7 +114,7 @@ const i18n = new VueI18n({
|
|||
})
|
||||
|
||||
Vue.use(Element, {
|
||||
i18n: key => i18n.vm._t(key)
|
||||
i18n: (key, value) => i18n.vm._t(key, value)
|
||||
})
|
||||
|
||||
new Vue({ i18n }).$mount('#app')
|
||||
|
@ -150,7 +150,7 @@ const i18n = new VueI18n({
|
|||
messages, // set locale messages
|
||||
})
|
||||
|
||||
ElementLocale.i18n(key => i18n.t(key))
|
||||
ElementLocale.i18n((key, value) => i18n.t(key, value))
|
||||
```
|
||||
|
||||
## 通过 CDN 的方式加载语言文件
|
||||
|
|
Loading…
Reference in New Issue