mirror of
https://github.com/ArthurDanjou/artchat.git
synced 2026-01-25 22:53:31 +01:00
feat: refactor language handling and improve UI components for better usability
This commit is contained in:
11
app/composables/language.ts
Normal file
11
app/composables/language.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
export function useLanguage() {
|
||||
const { setLocale } = useI18n()
|
||||
|
||||
async function changeLocale(newLocale: string) {
|
||||
await setLocale(newLocale as 'en' | 'fr' | 'es')
|
||||
}
|
||||
|
||||
return {
|
||||
changeLocale,
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user