From 99eaec85478f384ddb0ea45a9d9c95c4dce646f5 Mon Sep 17 00:00:00 2001 From: lain Date: Mon, 8 Jun 2020 17:22:07 +0200 Subject: Messages: Load languages asynchronously. Reduces the size of the initial app bundle by about half. --- src/App.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/App.js') diff --git a/src/App.js b/src/App.js index 6445335a..040138c9 100644 --- a/src/App.js +++ b/src/App.js @@ -47,7 +47,8 @@ export default { }), created () { // Load the locale from the storage - this.$i18n.locale = this.$store.getters.mergedConfig.interfaceLanguage + const val = this.$store.getters.mergedConfig.interfaceLanguage + this.$store.dispatch('setOption', { name: 'interfaceLanguage', value: val }) window.addEventListener('resize', this.updateMobileState) }, destroyed () { -- cgit v1.2.3-70-g09d2