mirror of
https://github.com/YunoHost/yunohost-portal.git
synced 2024-09-03 20:06:23 +02:00
nuxtconfig: use generated locales list
This commit is contained in:
parent
00793c986b
commit
74244e5a9a
1 changed files with 7 additions and 11 deletions
|
@ -1,3 +1,6 @@
|
||||||
|
import type { LocaleObject } from '@nuxtjs/i18n/dist/runtime/composables'
|
||||||
|
import locales from './maintenance/locales.json'
|
||||||
|
|
||||||
// https://nuxt.com/docs/api/configuration/nuxt-config
|
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||||
export default defineNuxtConfig({
|
export default defineNuxtConfig({
|
||||||
ssr: false,
|
ssr: false,
|
||||||
|
@ -17,9 +20,9 @@ export default defineNuxtConfig({
|
||||||
server: {
|
server: {
|
||||||
fs: {
|
fs: {
|
||||||
// For `./ynh-dev use-git yunohost-portal` to work
|
// For `./ynh-dev use-git yunohost-portal` to work
|
||||||
allow: ["/var/cache/ynh-dev/yunohost-portal/"]
|
allow: ['/var/cache/ynh-dev/yunohost-portal/'],
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
devtools: { enabled: true },
|
devtools: { enabled: true },
|
||||||
googleFonts: {
|
googleFonts: {
|
||||||
|
@ -37,14 +40,7 @@ export default defineNuxtConfig({
|
||||||
lazy: true,
|
lazy: true,
|
||||||
langDir: 'locales',
|
langDir: 'locales',
|
||||||
defaultLocale: 'en',
|
defaultLocale: 'en',
|
||||||
locales: [
|
locales: locales as LocaleObject[],
|
||||||
{
|
|
||||||
code: 'en',
|
|
||||||
iso: 'en',
|
|
||||||
name: 'English (United States)',
|
|
||||||
file: 'en.json',
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
colorMode: {
|
colorMode: {
|
||||||
preference: 'system',
|
preference: 'system',
|
||||||
|
|
Loading…
Add table
Reference in a new issue