35 lines
761 B
TypeScript
35 lines
761 B
TypeScript
// https://nuxt.com/docs/api/configuration/nuxt-config
|
|
export default defineNuxtConfig({
|
|
devtools: { enabled: true },
|
|
|
|
// Register modules
|
|
modules: [
|
|
'@pinia/nuxt',
|
|
'@nuxtjs/i18n',
|
|
],
|
|
|
|
// i18n configuration
|
|
i18n: {
|
|
strategy: 'no_prefix', // No URL prefix for locales
|
|
locales: [
|
|
{
|
|
code: 'en',
|
|
name: 'English'
|
|
},
|
|
{
|
|
code: 'zh',
|
|
name: '繁體中文'
|
|
}
|
|
],
|
|
defaultLocale: 'zh', // Set default language to Traditional Chinese
|
|
vueI18n: './i18n.config.ts', // Point to a separate config file for cleaner setup
|
|
detectBrowserLanguage: {
|
|
useCookie: true,
|
|
fallbackLocale: 'zh'
|
|
}
|
|
},
|
|
|
|
// Global CSS - We will import this in app.vue instead
|
|
css: [],
|
|
})
|