perf: preload JetBrains Mono font, remove unused api.github.com preconnect#998
perf: preload JetBrains Mono font, remove unused api.github.com preconnect#998
Conversation
…nnect - Add preload for jetbrains-mono-latin.woff2 to break the HTML->CSS->font waterfall chain (est ~290ms LCP savings) - Remove preconnect to api.github.com -- the GitHub star button iframe handles its own connection, preconnect was unused
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
🧰 Additional context used🧠 Learnings (1)📚 Learning: 2026-04-02T13:12:42.085ZApplied to files:
🔇 Additional comments (1)
WalkthroughModified the document head in 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
Pull request overview
This PR applies two Lighthouse-driven performance tweaks to the synthorg.io landing page by optimizing font loading and removing an unused early connection hint.
Changes:
- Added a
<link rel="preload">for the self-hosted JetBrains Mono WOFF2 font to reduce the CSS→font waterfall. - Removed an unused
<link rel="preconnect">tohttps://api.github.com.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Snapshot WarningsEnsure that dependencies are being submitted on PR branches. Re-running this action after a short time may resolve the issue. See the documentation for more information and troubleshooting advice. Scanned FilesNone |
There was a problem hiding this comment.
Code Review
This pull request updates site/src/layouts/Base.astro by removing a preconnect link to api.github.com and adding a preload link for the jetbrains-mono-latin.woff2 font. The reviewer suggests considering preloading geist-mono-latin.woff2 if it's used in the initial viewport, or removing its @font-face definition from global.css if it's not used, to further optimize performance and maintain a lean stylesheet.
| <!-- Self-hosted fonts (eliminates CLS and Google Fonts network dependency) --> | ||
| <link rel="preload" href="/fonts/inter-latin.woff2" as="font" type="font/woff2" crossorigin /> | ||
| <link rel="preload" href="/fonts/geist-latin.woff2" as="font" type="font/woff2" crossorigin /> | ||
| <link rel="preload" href="/fonts/jetbrains-mono-latin.woff2" as="font" type="font/woff2" crossorigin /> |
There was a problem hiding this comment.
While preloading JetBrains Mono is a great performance optimization for the critical path, consider also preloading Geist Mono (/fonts/geist-mono-latin.woff2) if it is used in the initial viewport.
Currently, inter-latin.woff2, geist-latin.woff2, and jetbrains-mono-latin.woff2 are preloaded, but geist-mono-latin.woff2 (defined in global.css) is missing. If it's used, it will still suffer from the waterfall delay. If it's not used, you might want to remove its @font-face definition from global.css to keep the stylesheet lean.
🤖 I have created a release *beep* *boop* --- ## [0.5.7](v0.5.6...v0.5.7) (2026-04-02) ### Features * comparison page -- SynthOrg vs agent orchestration frameworks ([#994](#994)) ([6f937ef](6f937ef)), closes [#981](#981) * event-driven and budget-driven ceremony scheduling strategies ([#995](#995)) ([f88e7b0](f88e7b0)), closes [#971](#971) [#972](#972) * template packs for post-setup additive team expansion ([#996](#996)) ([b45e14a](b45e14a)), closes [#727](#727) ### Performance * preload JetBrains Mono font, remove unused api.github.com preconnect ([#998](#998)) ([2a189c2](2a189c2)) * run only affected modules in pre-push hooks ([#992](#992)) ([7956e23](7956e23)) ### Maintenance * bump astro from 6.1.2 to 6.1.3 in /site in the all group ([#988](#988)) ([17b58db](17b58db)) * bump the all group across 1 directory with 2 updates ([#989](#989)) ([1ff462a](1ff462a)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Two small Lighthouse fixes for synthorg.io landing page:
Preload JetBrains Mono font -- breaks the HTML->CSS->font waterfall chain. Lighthouse shows this font at the end of the critical path (509ms). Preloading parallelizes the fetch with CSS loading (~290ms estimated LCP savings).
Remove unused preconnect to api.github.com -- the GitHub star button iframe handles its own connection to api.github.com. The preconnect was flagged as unused by Lighthouse because the timing is misaligned (preconnect fires early, button script loads late, connection closes before use).
Changes
site/src/layouts/Base.astro: added<link rel="preload">for jetbrains-mono-latin.woff2, removed<link rel="preconnect">for api.github.comTest Plan