You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
docs: add an App Hosting deployment guide for SSR (silent CSR fallback) #3719
A freshly deployed Angular SSR app on Firebase App Hosting can silently stop server-rendering and fall back to client-side rendering (CSR). The page still looks fine in a browser, but the server sends an almost-empty shell: crawlers and link previews see no content, and first paint is worse. There is no error in the deploy output or the browser, only a line in firebase functions:log.
The cause is proxy-header trust: App Hosting's proxy adds X-Forwarded-* headers that Angular's server engine does not trust by default, so it de-optimizes to CSR on every request.
If the response has no ng-server-context="ssr", the server is not server-rendering.
The gap
AngularFire has no deployment guide covering this. The existing docs/universal/ content still uses the deprecated @nguniversal stack (last updated mid-2023) and never mentions @angular/ssr. New SSR users hit the fallback silently.
Proposal
Add a docs/app-hosting.md guide (linked from the README) that documents the 30-second ng-server-context check and the two-step fix (npm update @angular/core @angular/ssr plus trustProxyHeaders: true), deferring to Firebase's App Hosting troubleshooting guide as the authoritative source. This affects both public deploy paths (a connected GitHub repo and firebase deploy), which build the same way.
Activity