uptime-kuma/src/App.vue

28 lines
478 B
Vue
Raw Normal View History

2021-06-25 13:55:49 +00:00
<template>
<router-view />
</template>
<script>
import { i18n, localeDirection } from "./i18n";
export default {
created() {
this.setPageLocale();
},
methods: {
setPageLocale() {
const html = document.documentElement
html.setAttribute('lang', this.$i18n.locale )
html.setAttribute('dir', localeDirection() )
}
},
watch: {
"$i18n.locale"() {
this.setPageLocale();
},
},
}
2021-06-25 13:55:49 +00:00
</script>