diff --git a/website/docs/en/blog/index.mdx b/website/docs/en/blog/index.mdx
index 388b6ebc9..4d25aa6f9 100644
--- a/website/docs/en/blog/index.mdx
+++ b/website/docs/en/blog/index.mdx
@@ -1,6 +1,7 @@
---
title: Overview
sidebar: false
+pageType: doc-wide
---
# Rslib blogs
diff --git a/website/docs/en/blog/introducing-rslib.mdx b/website/docs/en/blog/introducing-rslib.mdx
index 5114161b4..1a1aa689e 100644
--- a/website/docs/en/blog/introducing-rslib.mdx
+++ b/website/docs/en/blog/introducing-rslib.mdx
@@ -1,6 +1,7 @@
---
date: 2025-05-14 10:00:00
sidebar: false
+pageType: doc-wide
---
_May 14, 2025_
diff --git a/website/docs/en/guide/advanced/output-compatibility.mdx b/website/docs/en/guide/advanced/output-compatibility.mdx
index 3c5cef71d..6f6898bb0 100644
--- a/website/docs/en/guide/advanced/output-compatibility.mdx
+++ b/website/docs/en/guide/advanced/output-compatibility.mdx
@@ -102,6 +102,6 @@ export default defineConfig({
1. Configure `output.external` with `resolvedPolyfillToModules`, which you can import from [@rsbuild/plugin-node-polyfill](https://github.com/rspack-contrib/rsbuild-plugin-node-polyfill). This will externalize the polyfill modules to the installed polyfill dependencies.
2. Install used polyfill modules as dependencies.
- With the following steps, every usage of the polyfill module will be replaced by the corresponding module in the `externals` field. Checkout the of the example for more details.
+ With the above steps, every usage of the polyfill module will be replaced by the corresponding module in the `externals` field. Checkout the of the example for more details.
Check out the documentation of [@rsbuild/plugin-node-polyfill](https://github.com/rspack-contrib/rsbuild-plugin-node-polyfill), all the configurations are applicable for Rslib.
diff --git a/website/docs/zh/blog/index.mdx b/website/docs/zh/blog/index.mdx
index 4eb5eae99..7901a0de7 100644
--- a/website/docs/zh/blog/index.mdx
+++ b/website/docs/zh/blog/index.mdx
@@ -1,6 +1,7 @@
---
title: 总览
sidebar: false
+pageType: doc-wide
---
# Rslib 博客
diff --git a/website/docs/zh/blog/introducing-rslib.mdx b/website/docs/zh/blog/introducing-rslib.mdx
index 3f9dc23c2..8d397013a 100644
--- a/website/docs/zh/blog/introducing-rslib.mdx
+++ b/website/docs/zh/blog/introducing-rslib.mdx
@@ -1,6 +1,7 @@
---
date: 2025-05-14 10:00:00
sidebar: false
+pageType: doc-wide
---
_2025 年 5 月 14 日_
diff --git a/website/docs/zh/guide/advanced/output-compatibility.mdx b/website/docs/zh/guide/advanced/output-compatibility.mdx
index 138588c0e..f996c7ebb 100644
--- a/website/docs/zh/guide/advanced/output-compatibility.mdx
+++ b/website/docs/zh/guide/advanced/output-compatibility.mdx
@@ -102,6 +102,6 @@ export default defineConfig({
1. 配置 `output.external` 和 `resolvedPolyfillToModules`,你可以从 [@rsbuild/plugin-node-polyfill](https://github.com/rspack-contrib/rsbuild-plugin-node-polyfill) 导入。这将 polyfill 模块 external 到已安装的 polyfill 依赖中。
2. 安装使用的 polyfill 模块作为依赖。
- 通过以下步骤,每个 polyfill 模块的使用将被替换为 `externals` 字段中的相应模块。更多详细信息,请查看 的示例。
+ 通过以上步骤,每个 polyfill 模块的使用将被替换为 `externals` 字段中的相应模块。更多详细信息,请查看 的示例。
更多详细信息,请查看 [@rsbuild/plugin-node-polyfill](https://github.com/rspack-contrib/rsbuild-plugin-node-polyfill) 文档,所有配置均适用于 Rslib。
diff --git a/website/rspress.config.ts b/website/rspress.config.ts
index 5cb5a883b..229a4e244 100644
--- a/website/rspress.config.ts
+++ b/website/rspress.config.ts
@@ -16,8 +16,25 @@ import { pluginFontOpenSans } from 'rspress-plugin-font-open-sans';
const siteUrl = 'https://rslib.rs';
const description = 'The Rsbuild-based library development tool';
+const descriptionZh = '基于 Rsbuild 的库构建工具';
export default defineConfig({
+ title: 'Rslib',
+ description:
+ 'Rslib is a library development tool that leverages the well-designed configurations and plugins of Rsbuild.',
+ lang: 'en',
+ icon: 'https://assets.rspack.rs/rslib/rslib-logo-192x192.png',
+ logo: 'https://assets.rspack.rs/rslib/rslib-logo-192x192.png',
+ logoText: 'Rslib',
+ root: path.join(__dirname, 'docs'),
+ markdown: {
+ shiki: {
+ transformers: [transformerNotationHighlight(), transformerNotationDiff()],
+ },
+ },
+ search: {
+ codeBlocks: true,
+ },
plugins: [
pluginAlgolia(),
pluginFontOpenSans(),
@@ -52,22 +69,6 @@ export default defineConfig({
siteUrl,
}),
],
- root: path.join(__dirname, 'docs'),
- lang: 'en',
- title: 'Rslib',
- description:
- 'Rslib is a library development tool that leverages the well-designed configurations and plugins of Rsbuild.',
- icon: 'https://assets.rspack.rs/rslib/rslib-logo-192x192.png',
- logo: 'https://assets.rspack.rs/rslib/rslib-logo-192x192.png',
- logoText: 'Rslib',
- markdown: {
- shiki: {
- transformers: [transformerNotationHighlight(), transformerNotationDiff()],
- },
- },
- search: {
- codeBlocks: true,
- },
route: {
cleanUrls: true,
// exclude document fragments from routes
@@ -102,39 +103,22 @@ export default defineConfig({
content: 'https://discord.gg/XsaKEEk4mW',
},
],
+ editLink: {
+ docRepoBaseUrl:
+ 'https://github.com/web-infra-dev/rslib/tree/main/website/docs',
+ },
locales: [
{
lang: 'en',
label: 'English',
title: 'Rslib',
description,
- editLink: {
- docRepoBaseUrl:
- 'https://github.com/web-infra-dev/rslib/tree/main/website/docs',
- text: '📝 Edit this page on GitHub',
- },
},
{
lang: 'zh',
label: '简体中文',
title: 'Rslib',
- outlineTitle: '目录',
- prevPageText: '上一页',
- nextPageText: '下一页',
- searchPlaceholderText: '搜索文档',
- searchNoResultsText: '无法找到相关搜索结果',
- searchSuggestedQueryText: '请使用不同的关键字重试',
- description: '基于 Rsbuild 的库构建工具',
- overview: {
- filterNameText: '过滤',
- filterPlaceholderText: '输入关键词',
- filterNoResultText: '未找到匹配的 API',
- },
- editLink: {
- docRepoBaseUrl:
- 'https://github.com/web-infra-dev/rslib/tree/main/website/docs',
- text: '📝 在 GitHub 上编辑此页',
- },
+ description: descriptionZh,
},
],
},