Skip to content

Commit 1e8b367

Browse files
docs(zh): sync and tweak translations (#3684)
closes #3682 Co-authored-by: ZHANG PENG <[email protected]>
1 parent 0b45abd commit 1e8b367

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

Diff for: docs/zh/guide/what-is-vitepress.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ VitePress 旨在使用 Markdown 生成内容时提供出色的开发体验。
3434

3535
## 性能 {#performance}
3636

37-
与许多传统的 SSG 不同,VitePress 生成的站点实际上是一个[单页应用程序](https://en.wikipedia.org/wiki/Single-page_application) (SPA)。
37+
与许多传统的 SSG 不同,每次导航都会导致页面完全重新加载,VitePress 生成的网站在初次访问时提供静态 HTML,但它变成了[单页应用程序](https://en.wikipedia.org/wiki/Single-page_application)SPA)进行站点内的后续导航。我们认为,这种模式为性能提供了最佳平衡:
3838

3939
- **快速的初始加载**
4040

41-
对任何页面的初次访问都将会是静态的、预呈现的 HTML,以实现极快的加载速度和最佳的 SEO。然后页面加载一个 JavaScript bundle,将页面变成 Vue SPA (这被称为“激活”)。激活是非常快的:[PageSpeed Insights](https://pagespeed.web.dev/report?url=https%3A%2F%2Fvitepress.dev%2F) 上,典型的 VitePress 站点即使在网络速度较慢的低端移动设备上也能获得近乎完美的性能分数。
41+
对任何页面的初次访问都将会是静态的、预呈现的 HTML,以实现极快的加载速度和最佳的 SEO。然后页面加载一个 JavaScript bundle,将页面变成 Vue SPA (这被称为“激活”)。与 SPA 激活缓慢的常见假设不同,由于 Vue 3 良好的原始性能和编译优化,这个过程实际上非常快。[PageSpeed Insights](https://pagespeed.web.dev/report?url=https%3A%2F%2Fvitepress.dev%2F) 上,典型的 VitePress 站点即使在网络速度较慢的低端移动设备上也能获得近乎完美的性能分数。
4242

4343
- **加载完成后可以快速切换**
4444

Diff for: docs/zh/reference/site-config.md

+9-2
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ export default {
377377
- 类型:`string`
378378
- 默认值: `.`
379379

380-
markdown 页面的目录,相对于项目根目录。另请参阅[根目录和源目录](../guide/routing#root-and-source-directory)
380+
相对于项目根目录的 markdown 文件所在的文件夹。另请参阅[根目录和源目录](../guide/routing#root-and-source-directory)
381381

382382
```ts
383383
export default {
@@ -390,7 +390,7 @@ export default {
390390
- 类型:`string`
391391
- 默认值: `undefined`
392392

393-
用于匹配应作为源内容输出的 markdown 文件的 [全局模式](https://github.com/mrmlnc/fast-glob#pattern-syntax)
393+
用于匹配应排除作为源内容输出的 markdown 文件,语法详见 [glob pattern](https://github.com/mrmlnc/fast-glob#pattern-syntax)
394394

395395
```ts
396396
export default {
@@ -471,6 +471,13 @@ export default {
471471
}
472472
```
473473

474+
### metaChunk <Badge type="warning" text="experimental" />
475+
476+
- 类型:`boolean`
477+
- 默认值:`false`
478+
479+
当设置为 `true` 时,将页面元数据提取到单独的 JavaScript 块中,而不是内联在初始 HTML 中。这使每个页面的 HTML 负载更小,并使页面元数据可缓存,从而当站点中有很多页面时可以减少服务器带宽。
480+
474481
### mpa <Badge type="warning" text="experimental" />
475482

476483
- 类型:`boolean`

0 commit comments

Comments
 (0)