mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-23 14:54:05 +00:00
Update src/mixins/lang.js
Co-authored-by: Matthew Nickson <mnickson@sidingsmedia.com>
This commit is contained in:
parent
1ceb8e98d6
commit
a50209b6c8
1 changed files with 4 additions and 1 deletions
|
@ -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 a new issue