Repository navigation
Conversation
next-themes writes the portal theme onto <html> as a `light` or `dark` class and an inline color-scheme, and leaves both there when the portal's providers unmount. Going from the portal back to a marketing page without a reload (the browser's back button, or a header link) kept the portal's light gray ramp on the dark site: body text went from #9ca3af to #4c5553 on near-black until the page was refreshed. The portal providers now clear both on unmount. Re-entering the portal mounts next-themes again, which applies the theme as before.
App Hosting puts Cloud CDN in front of Cloud Run, and it already serves the homepage from cache (Cdn-Cache-Status: hit) because the proxy marks it public. /team, /bootcamp and /status are prerendered too and revalidate every five minutes, but they fell through to the no-store default, so every visit went to the single Cloud Run region instead of an edge near the visitor. They now get the homepage's header. Exact paths only, so a dynamic page added under one of them later does not inherit public caching.
…-back fix(mainweb): drop the portal theme from <html> when leaving the portal
…ages perf(mainweb): let the CDN cache /team, /bootcamp and /status
Contributor
1 similar comment
Contributor
Contributor
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
[Medium impact] The PR appears safe to merge; no actionable issues were found.
|
Contributor
|
Visit the preview URL for this PR (updated for commit 44000d7): https://hacklytics2027--pr-578-r8a0hzen.web.app (expires Fri, 13 Nov 2026 14:07:22 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: c48ba34db61581e25fe2978355160b5eefe0e83f |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Theme fix on leaving the portal (#576); CDN caching for /team, /bootcamp, /status (#577).
Note
Low Risk
Themed markup cleanup is client-only; cache headers apply only to fixed, cookie-independent paths—stale content risk is bounded by the five-minute max-age.
Overview
Portal theme: When the portal unmounts (e.g. browser back to a marketing page),
next-themesused to leavelight/darkandcolor-schemeon<html>. A newClearThemeOnLeaveeffect runs cleanup on unmount so marketing pages get their own styling again without a full reload.Caching: The HTTP caching proxy now treats
/bootcamp,/status, and/teamlike the home page:public, max-age=300, must-revalidatefor exact path matches only (not subpaths), so prerendered routes that don’t rely on cookies can be served from the CDN instead of always hitting the origin.Reviewed by Cursor Bugbot for commit 44000d7. Bugbot is set up for automated code reviews on this repo. Configure here.