-
-
Notifications
You must be signed in to change notification settings - Fork 199
feat(ssg-md): support Overview and HomeLayout #2933
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
✅ 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, 2 projects with changes. 📊 Quick Summary
📋 Detailed Reports (Click to expand)📁 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.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds support for rendering Overview and HomeLayout components in SSG (Static Site Generation) markdown mode by introducing markdown-formatted output when process.env.__SSR_MD__ is true.
Key Changes
- Modified App.tsx to render Layout component instead of Content in SSR_MD mode
- Added conditional markdown rendering for HomeLayout and Overview components
- Reorganized hook call ordering in Layout component to accommodate SSR_MD checks
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 9 comments.
Show a summary per file
| File | Description |
|---|---|
packages/core/src/runtime/App.tsx |
Updated SSR_MD mode to render full Layout with Root wrapper instead of just Content |
packages/core/src/theme/layout/Layout/index.tsx |
Moved hook calls (useSetup, useScrollReset, useRedirect4FirstVisit) after SSR_MD conditional check |
packages/core/src/theme/layout/HomeLayout/index.tsx |
Added HomeLayoutMarkdown function to generate markdown representation of hero and features sections |
packages/core/src/theme/layout/DocLayout/index.tsx |
Added SSR_MD conditional to return simplified layout with Overview or DocContent |
packages/core/src/theme/components/Overview/index.tsx |
Added OverviewMarkdown function to generate markdown representation of overview groups and items |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
feat(ssg-md): support Overview and HomeLayout
Related Issue
Checklist