fix: root page does not have analytic code - #2261
Conversation
WalkthroughThe Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🔇 Additional comments (4)
Tip 📝 Customizable high-level summaries are now available in beta!You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.
Example instruction:
Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
fix: root page does not have analytic code
当前主页(index.html)是直接从 embed fs 内读取的,这导致 umami 和 GA 的替换逻辑未替换主页。
这个 PR 修改了主页的读取逻辑,强制使用替换逻辑替换后的主页,保证统计代码生效。
The root page https://xxx.xxx/ is served directly from the embed file system, which always delivers the original version of the index file — one that hasn’t been patched with the analytics code.
This PR prevents the static file system from serving the root page directly, ensuring that the version with the analytics code is always used.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.