mirror of
https://github.com/YunoHost/yunohost-admin.git
synced 2024-09-03 20:06:15 +02:00
locales: wait locales loading before mounting the vue app
This commit is contained in:
parent
e3cad1c2b3
commit
76895be395
2 changed files with 9 additions and 9 deletions
|
@ -80,7 +80,7 @@ function initDefaultLocales () {
|
|||
|
||||
store.dispatch('UPDATE_LOCALE', locale)
|
||||
store.dispatch('UPDATE_FALLBACKLOCALE', fallbackLocale || 'en')
|
||||
loadLocaleMessages('en')
|
||||
return loadLocaleMessages('en')
|
||||
}
|
||||
|
||||
export {
|
||||
|
|
|
@ -55,13 +55,13 @@ requireComponent.keys().forEach((fileName) => {
|
|||
registerGlobalErrorHandlers()
|
||||
|
||||
// Load default locales translations files and setup store data
|
||||
initDefaultLocales()
|
||||
initDefaultLocales().then(() => {
|
||||
const app = new Vue({
|
||||
store,
|
||||
router,
|
||||
i18n,
|
||||
render: h => h(App)
|
||||
})
|
||||
|
||||
const app = new Vue({
|
||||
store,
|
||||
router,
|
||||
i18n,
|
||||
render: h => h(App)
|
||||
app.$mount('#app')
|
||||
})
|
||||
|
||||
app.$mount('#app')
|
||||
|
|
Loading…
Add table
Reference in a new issue