rspress-description-generator
Rspress Description Generator
The description field in Rspress frontmatter generates <meta name="description" content="..."> tags, which are used for search engine snippets, social media previews, and AI-oriented formats like llms.txt.
Step 1 — Locate the docs root
- Find the Rspress config file. Search for
rspress.config.ts,.js,.mjs, or.cjs. It may be at the project root or inside a subdirectory likewebsite/. - Read the config and extract the
rootoption.- The value might be a plain string (
root: 'docs') or a JS expression (root: path.join(__dirname, 'docs')). In either case, determine the resolved directory path. - If
rootis set, resolve it relative to the config file's directory. - If
rootis not set, default todocsrelative to the config file's directory.
- The value might be a plain string (
- Confirm the directory exists. If neither
docsnor the configured root exists, check fordocas a fallback.
Step 2 — Detect i18n structure
Rspress i18n projects place language subdirectories (e.g., en/, zh/) directly under the docs root:
More from rstackjs/agent-skills
rsbuild-best-practices
Rsbuild best practices for config, CLI workflow, type checking, bundle optimization, assets, and debugging. Use when writing, reviewing, or troubleshooting Rsbuild projects.
557rslib-best-practices
Rslib best practices for config, CLI workflow, output, declaration files, dependency handling, build optimization and toolchain integration. Use when writing, reviewing, or troubleshooting Rslib projects.
405rspack-v2-upgrade
Use when upgrading a Rspack 1.x project to v2, including dependency and configuration updates.
236rstest-best-practices
Rstest best practices for config, CLI workflow, test writing, mocking, snapshot testing, DOM testing, coverage, multi-project setup, CI integration, performance and debugging. Use when writing, reviewing, or troubleshooting Rstest test projects.
227rspack-best-practices
Rspack best practices for config, CLI workflow, type checking, CSS, bundle optimization, assets and profiling. Use when writing, reviewing, or troubleshooting Rspack projects.
222rsbuild-v2-upgrade
Use when upgrading a Rsbuild 1.x project to v2, including dependency and configuration updates.
206