-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Upgrading to 16+ breaks pre-rendering with SSR #3624
Comments
This issue does not seem to follow the issue template. Make sure you provide all the required information. |
If I change prerender to not dynamically discover routes and provide just 1 route, it gives the same error but on a different part of the prerendering
Prerender code where failure occurs: |
When moving from
@angular/fire
7.6.1 to 16 or 17, the prerendering with SSR is failing.The following works:
"@angular/common": "^17.3.12",
"@angular/fire": "^7.6.1",
"firebase": "^10.14.1"
The error during prerender with any @angular/fire 16 or 17 version is down below. I assume the issue is that it cannot load the modules the right way with the server for prerender but not sure why. I'm using
"target": "ES2022",
"module": "ES2022",
in my TS config.
Error
It gets to prerendering stage (so the project builds fine).
⠋ Prerendering 1 route(s) to /dist/retail/browser.../dist/retail/server/main.js:1
Then I get a ton of the compiled code
Then I see this syntax error:
I'm not sure how to debug further. I can't seem to see what the difference in 16+ and 7.6.1 is that would cause this issue unless its something to do with commonjs to esm.
I was going to post on the SSR repo but since this issue spawns specifically around an angular/fire update, I thought it would be more appropriate here.
This is the server.ts:
The text was updated successfully, but these errors were encountered: