docs: add rspress-plugin-file-tree and use tree syntax for file tree code blocks#2976
docs: add rspress-plugin-file-tree and use tree syntax for file tree code blocks#2976
Conversation
## 完成总结 已完成以下修改: ### 1. 安装配置 `rspress-plugin-file-tree` 插件 - **package.json**: 添加了 `rspress-plugin-file-tree` 依赖 - **rspress.config.ts**: - 导入 `import pluginFileTree from 'rspress-plugin-file-tree';` - 在 plugins 数组中添加 `pluginFileTree()` ### 2. 将所有文件树代码块从 `txt` 改为 `tree` 修改了以下 22 个文件中的文件树代码块: **英文文档 (11 个文件)**: - `docs/en/guide/start/introduction.mdx` - `docs/en/guide/basic/ssg.mdx` - `docs/en/guide/basic/ssg-md.mdx` (2 处) - `docs/en/guide/basic/auto-nav-sidebar.mdx` (5 处) - `docs/en/guide/basic/i18n.mdx` (2 处) - `docs/en/guide/basic/multi-version.mdx` - `docs/en/guide/basic/conventional-route.mdx` (2 处) - `docs/en/guide/basic/custom-theme.mdx` (3 处) - `docs/en/guide/basic/static-assets.mdx` - `docs/en/guide/advanced/overview-page.mdx` (3 处) - `docs/en/plugin/official-plugins/typedoc.mdx` **中文文档 (11 个文件)**: - `docs/zh/guide/start/introduction.mdx` - `docs/zh/guide/basic/ssg.mdx` - `docs/zh/guide/basic/ssg-md.mdx` (2 处) - `docs/zh/guide/basic/auto-nav-sidebar.mdx` (5 处) - `docs/zh/guide/basic/i18n.mdx` (2 处) - `docs/zh/guide/basic/multi-version.mdx` - `docs/zh/guide/basic/conventional-route.mdx` (2 处) - `docs/zh/guide/basic/custom-theme.mdx` (2 处) - `docs/zh/guide/basic/static-assets.mdx` - `docs/zh/guide/advanced/overview-page.mdx` (3 处) - `docs/zh/plugin/official-plugins/typedoc.mdx` 注意:`commands.mdx` 和部分 `ssg-md.mdx` 中的 `txt` 代码块保持不变,因为它们不是文件树结构(是命令行帮助输出和 markdown 内容示例)。
✅ Deploy Preview for rspress-v2 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Rsdoctor Bundle Diff AnalysisFound 3 projects in monorepo, 3 projects with changes. 📊 Quick Summary
📋 Detailed Reports (Click to expand)📁 nodePath:
📦 Download Diff Report: node Bundle Diff 📁 node_mdPath:
📦 Download Diff Report: node_md Bundle Diff 📁 webPath:
📦 Download Diff Report: web Bundle Diff Generated by Rsdoctor GitHub Action |
There was a problem hiding this comment.
Pull request overview
This PR adds support for the rspress-plugin-file-tree plugin to enable better visualization of directory structures in documentation, and systematically converts all directory structure code blocks from txt to tree language syntax across both Chinese and English documentation.
- Added
rspress-plugin-file-tree@^1.0.1dependency and configured it in the rspress configuration - Updated 27 documentation files to use
treelanguage syntax for directory structure code blocks - Ensures consistent rendering of file tree structures across the entire documentation site
Reviewed changes
Copilot reviewed 24 out of 25 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| website/rspress.config.ts | Imports and configures the file tree plugin |
| website/package.json | Adds rspress-plugin-file-tree dependency |
| website/docs/zh/plugin/official-plugins/typedoc.mdx | Converts directory structure from txt to tree syntax |
| website/docs/zh/guide/start/introduction.mdx | Converts directory structure from txt to tree syntax |
| website/docs/zh/guide/basic/static-assets.mdx | Converts directory structure from txt to tree syntax |
| website/docs/zh/guide/basic/ssg.mdx | Converts build output structure from txt to tree syntax |
| website/docs/zh/guide/basic/ssg-md.mdx | Converts build output structures from txt to tree syntax |
| website/docs/zh/guide/basic/multi-version.mdx | Converts directory structure from txt to tree syntax |
| website/docs/zh/guide/basic/i18n.mdx | Converts directory structures from txt to tree syntax |
| website/docs/zh/guide/basic/custom-theme.mdx | Converts theme directory structures from txt to tree syntax |
| website/docs/zh/guide/basic/conventional-route.mdx | Converts directory structures from txt to tree syntax |
| website/docs/zh/guide/basic/auto-nav-sidebar.mdx | Converts directory structures from txt to tree syntax |
| website/docs/zh/guide/advanced/overview-page.mdx | Converts directory structures from txt to tree syntax |
| website/docs/en/plugin/official-plugins/typedoc.mdx | Converts directory structure from txt to tree syntax |
| website/docs/en/guide/start/introduction.mdx | Converts directory structure from txt to tree syntax |
| website/docs/en/guide/basic/static-assets.mdx | Converts directory structure from txt to tree syntax |
| website/docs/en/guide/basic/ssg.mdx | Converts build output structure from txt to tree syntax |
| website/docs/en/guide/basic/ssg-md.mdx | Converts build output structures from txt to tree syntax |
| website/docs/en/guide/basic/multi-version.mdx | Converts directory structure from txt to tree syntax |
| website/docs/en/guide/basic/i18n.mdx | Converts directory structures from txt to tree syntax |
| website/docs/en/guide/basic/custom-theme.mdx | Converts theme directory structures from txt to tree syntax |
| website/docs/en/guide/basic/conventional-route.mdx | Converts directory structures from txt to tree syntax |
| website/docs/en/guide/basic/auto-nav-sidebar.mdx | Converts directory structures from txt to tree syntax |
| website/docs/en/guide/advanced/overview-page.mdx | Converts directory structures from txt to tree syntax |
| pnpm-lock.yaml | Updates lockfile with new dependencies and their transitive dependencies |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
1. 识别 `<-- "..."` 形式的注释(不仅仅是 `//` 和 `#`) 2. 如果开头第一行是 `.`,则跳过第一行 但是这个插件的源码位于另一个 worktree(`/var/folders/wt/r13w69wd7v9bh3b_t_p24sjm0000gn/T/vibe-kanban/worktrees/40d3-rspress-plugin-f/rspress-plugins/packages/rspress-plugin-file-tree`),不在当前的 rspress 仓库中。 你需要我在当前会话中修改那个插件的源码吗?还是这个任务应该在另一个 worktree/会话中处理?
Summary
Add
rspress-plugin-file-treeplugin to the website and update all file tree code blocks to use thetreelanguage syntax for enhanced visual rendering.before
after
Related Issue
N/A
Checklist
AI Summary
Changes Made
Added
rspress-plugin-file-treepluginwebsite/package.jsonwebsite/rspress.config.tsUpdated file tree code blocks (22 files, 40+ code blocks)
Files Modified
Configuration:
website/package.json- Addedrspress-plugin-file-treedependencywebsite/rspress.config.ts- Imported and configuredpluginFileTree()English Documentation (11 files):
docs/en/guide/start/introduction.mdxdocs/en/guide/basic/ssg.mdx,ssg-md.mdx,auto-nav-sidebar.mdxdocs/en/guide/basic/i18n.mdx,multi-version.mdx,conventional-route.mdxdocs/en/guide/basic/custom-theme.mdx,static-assets.mdxdocs/en/guide/advanced/overview-page.mdxdocs/en/plugin/official-plugins/typedoc.mdxChinese Documentation (11 files):
Why These Changes
The
rspress-plugin-file-treeplugin provides enhanced visual rendering for file tree structures in documentation. By using thetreesyntax instead of plaintxt, file trees will be rendered with proper styling, making the documentation more readable and visually appealing.This PR was written using Vibe Kanban