diff --git a/.vitepress/theme/components/SupportedVersions.vue b/.vitepress/theme/components/SupportedVersions.vue index b2530ee4..a85aa3b6 100644 --- a/.vitepress/theme/components/SupportedVersions.vue +++ b/.vitepress/theme/components/SupportedVersions.vue @@ -6,11 +6,11 @@ declare const __VITE_VERSION__: string // Constants const supportedVersionMessage = { color: 'var(--vp-c-brand-1)', - text: 'supported', + text: '支持', } const notSupportedVersionMessage = { color: 'var(--vp-c-danger-1)', - text: 'not supported', + text: '不支持', } const previousMajorLatestMinors: Record = { '2': '2.9', @@ -90,7 +90,7 @@ function versionsToText(versions: string[]) { if (versions.length === 0) return '' if (versions.length === 1) return versions[0] return ( - versions.slice(0, -1).join(', ') + ' and ' + versions[versions.length - 1] + versions.slice(0, -1).join(', ') + ' 和 ' + versions[versions.length - 1] ) } @@ -106,34 +106,33 @@ function isValidViteVersion(version: string) {

- If you're using Vite + 如果你使用的是 Vite , it is + />, 它是 {{ checkedResult.text }}. + >。

diff --git a/config/index.md b/config/index.md index cbcd9743..4266bf2d 100644 --- a/config/index.md +++ b/config/index.md @@ -117,10 +117,10 @@ export default defineConfig(({ mode }) => { const env = loadEnv(mode, process.cwd(), '') return { define: { - // Provide an explicit app-level constant derived from an env var. + // 提供从 env var 派生的显式应用程序级常量。 __APP_ENV__: JSON.stringify(env.APP_ENV), }, - // Example: use an env var to set the dev server port conditionally. + // 例如:使用 env var 有条件地设置开发服务器端口。 server: { port: env.APP_PORT ? Number(env.APP_PORT) : 5173, }, diff --git a/config/shared-options.md b/config/shared-options.md index f9719599..5133062d 100644 --- a/config/shared-options.md +++ b/config/shared-options.md @@ -189,7 +189,7 @@ declare const __APP_VERSION__: string | ((name: string, filename: string, css: string) => string) hashPrefix?: string /** - * default: undefined + * 默认:undefined */ localsConvention?: | 'camelCase'