chore(website): upgrade Rspress to v2.0.8#609
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the Rslint website to Rspress v2, involving significant dependency upgrades and configuration adjustments. Key changes include setting the package type to module, updating theme imports to use the original layout, and migrating to the official sitemap plugin. Feedback suggests including siteUrl in the top-level configuration for better integration with internal features and replacing __dirname with relative paths to ensure compatibility with ES modules.
There was a problem hiding this comment.
Pull request overview
Upgrades the website’s Rspress setup to v2.0.8 and updates configuration to match the newer plugin/theme/runtime expectations.
Changes:
- Bump
@rspress/coreto^2.0.8and migrate sitemap to@rspress/plugin-sitemap. - Switch website runtime/theme wiring to
@rspress/core/theme-originaland simplify related config. - Move Tailwind integration to PostCSS ESM config and remove the old Tailwind config file.
Reviewed changes
Copilot reviewed 5 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| website/tsconfig.json | Removes baseUrl while keeping paths aliases. |
| website/theme/index.tsx | Switches base theme imports/exports to theme-original. |
| website/tailwind.config.js | Removes the previous Tailwind config file. |
| website/rspress.config.ts | Updates sitemap plugin usage and aligns Rspress config with v2 runtime. |
| website/postcss.config.js | Adds ESM PostCSS config for Tailwind’s PostCSS plugin. |
| website/package.json | Sets ESM package mode and upgrades Rspress deps / plugin list. |
| pnpm-lock.yaml | Locks upgraded Rspress/Rsbuild dependency graph. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
Comments suppressed due to low confidence (1)
website/tsconfig.json:18
compilerOptions.pathsremains configured, butbaseUrlwas removed. TypeScript resolvespathsmappings relative tobaseUrland can ignore/disable them ifbaseUrlisn’t set, which would break aliases like@components/*and@/*in TS/IDE typechecking. If these aliases are still intended, re-add"baseUrl": "."(or use an alternative alias mechanism that TypeScript understands).
"paths": {
"@theme": ["./theme"],
"@components/*": ["./theme/components/*"],
"@zh/*": ["./docs/zh/*"],
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Deploying rslint with
|
| Latest commit: |
deef41b
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://e4ee8dcd.rslint.pages.dev |
| Branch Preview URL: | https://chenjiahan-chore-upgrade-rsp.rslint.pages.dev |
Summary
@rspress/core2.0.0-rc.0to^2.0.8and replace the old sitemap/llms plugin setup with the supported@rspress/plugin-sitemapconfiguration.baseUrl, and importing the custom theme from@rspress/core/theme-original.pnpm --filter @rslint/website build.Related Links
Checklist