From 85154a5b463f88ce480e8c9d448d7ee7d265e025 Mon Sep 17 00:00:00 2001 From: leejooy96 Date: Tue, 5 Nov 2024 18:58:22 +0900 Subject: [PATCH] chore: simplify code --- docs/src/.vitepress/config.mts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/src/.vitepress/config.mts b/docs/src/.vitepress/config.mts index 765f631..f74b913 100644 --- a/docs/src/.vitepress/config.mts +++ b/docs/src/.vitepress/config.mts @@ -6,9 +6,10 @@ import { VitePressI18nOptions } from 'vitepress-i18n/dist/types' const capitalizeFirst = (str: string): string => str.charAt(0).toUpperCase() + str.slice(1) const defaultLocale: string = 'en' +const supportLocales = [defaultLocale, 'ko'] const vitePressI18nConfigs: VitePressI18nOptions = { - locales: [defaultLocale, 'ko'], + locales: supportLocales, rootLocale: defaultLocale, searchProvider: 'local', description: { @@ -36,7 +37,7 @@ const vitePressI18nConfigs: VitePressI18nOptions = { } const vitePressSidebarConfigs: VitePressSidebarOptions = [ - ...[defaultLocale, 'ko'].map((lang) => { + ...supportLocales.map((lang) => { return { collapsed: false, useTitleFromFileHeading: true,