Messages: Load languages asynchronously.
Reduces the size of the initial app bundle by about half.
This commit is contained in:
parent
acbef1ebdc
commit
99eaec8547
5 changed files with 80 additions and 32 deletions
|
@ -46,11 +46,13 @@ Vue.use(VBodyScrollLock)
|
|||
|
||||
const i18n = new VueI18n({
|
||||
// By default, use the browser locale, we will update it if neccessary
|
||||
locale: currentLocale,
|
||||
locale: 'en',
|
||||
fallbackLocale: 'en',
|
||||
messages
|
||||
messages: messages.default
|
||||
})
|
||||
|
||||
messages.setLanguage(i18n, currentLocale)
|
||||
|
||||
const persistedStateOptions = {
|
||||
paths: [
|
||||
'config',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue