-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
feat: 支持3.x的htmlSuffix、dynamicRoot配置 #12400
base: master
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Ignored Deployment
|
Warning Rate Limit Exceeded@flgame has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 4 minutes and 46 seconds before requesting another review. How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Walkthrough此次更改主要集中在 Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
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.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts (10 hunks)
Files not reviewed due to errors (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts (no review received)
Co-authored-by: Sakina <59400654+fz6m@users.noreply.github.com>
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.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts (10 hunks)
Files skipped from review as they are similar to previous changes (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts
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.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts (9 hunks)
Files skipped from review as they are similar to previous changes (1)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts
@fz6m 已解答并修改 |
|
@fz6m
|
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.
Actionable comments posted: 1
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (7)
- examples/export-static/.umirc.ts (1 hunks)
- examples/export-static/package.json (1 hunks)
- examples/export-static/src/pages/bar.css (1 hunks)
- examples/export-static/src/pages/foo.less (1 hunks)
- examples/export-static/src/pages/index.tsx (1 hunks)
- examples/export-static/src/pages/page1/index.tsx (1 hunks)
- packages/preset-umi/src/features/exportStatic/exportStatic.ts (9 hunks)
Files skipped from review due to trivial changes (5)
- examples/export-static/.umirc.ts
- examples/export-static/package.json
- examples/export-static/src/pages/bar.css
- examples/export-static/src/pages/foo.less
- examples/export-static/src/pages/page1/index.tsx
Additional comments not posted (6)
examples/export-static/src/pages/index.tsx (1)
23-25
: 正确处理了带.html
后缀和不带后缀的路由,符合PR目标。packages/preset-umi/src/features/exportStatic/exportStatic.ts (5)
22-40
: 此函数用于判断是否应将路由视为HTML路由,逻辑清晰且正确处理了特殊字符和路由类型。
41-48
: 此函数正确处理了HTML后缀和特殊路径(如根路径和404路径)。逻辑简洁有效。
52-62
: 此函数从路由生成HTML数据,正确使用了isHtmlRoute
和getHtmlPath
函数,并特别处理了404路由。
152-153
: 配置模式中正确添加了htmlSuffix
和dynamicRoot
。使用Zod进行验证是一个稳健的选择。
334-349
: 路由修改逻辑根据HTML后缀设置复制并修改路由。使用getHtmlPath
函数调整路由路径,实现与PR目标一致。
|
#12301
Summary by CodeRabbit
新功能
HomePage
和Page1
,提供基本的主页和页面布局。.bar
和.foo
等样式。改进
publicPath
和资源路径的处理。hydrate
逻辑。