mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-10-01 01:25:45 -04:00
Update src/mixins/lang.js
Co-authored-by: Matthew Nickson <mnickson@sidingsmedia.com>
This commit is contained in:
parent
1ceb8e98d6
commit
a50209b6c8
@ -30,7 +30,10 @@ export default {
|
||||
localStorage.locale = lang;
|
||||
setPageLocale();
|
||||
},
|
||||
/** Change the language for the current page (no localstore set) */
|
||||
/**
|
||||
* Change the language for the current page (no localstore set)
|
||||
* @param {string} lang Code of language to switch to.
|
||||
*/
|
||||
async changeCurrentPageLang(lang) {
|
||||
let message = (await langModules["../lang/" + lang + ".json"]()).default;
|
||||
this.$i18n.setLocaleMessage(lang, message);
|
||||
|
Loading…
Reference in New Issue
Block a user