Skip to content

Commit 20dd656

Browse files
committed
chore: fix html validation errors
1 parent ad567da commit 20dd656

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

app/utils/i18n.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import { useI18n as useOriginalI18n } from 'vue-i18n'
22

33
export function useI18n() {
4-
const { t, d, n, ...rest } = useOriginalI18n()
4+
const i18n = useOriginalI18n()
5+
6+
const { t, d, n, ...rest } = i18n
57

68
return {
79
...rest,
@@ -13,6 +15,6 @@ export function useI18n() {
1315

1416
export function wrapI18n<T extends (...args: any[]) => any>(t: T): T {
1517
return <T>((...args: any[]) => {
16-
return isHydrated.value ? t(...args) : ''
18+
return import.meta.server ? t(...args) : isHydrated.value ? t(...args) : ''
1719
})
1820
}

0 commit comments

Comments
 (0)