Build fails in Angular SSR application with route parameters #28948
Labels
angular/build:application
area: @angular/build
freq1: low
Only reported by a handful of users who observe it rarely
severity5: regression
type: bug/fix
Command
build
Is this a regression?
The previous version in which this bug was not present was
No response
Description
I have added Angular SSR in an existing Angular app with routing enabled and when I run
ng build
I get the following error:The 'products/:id' route uses prerendering and includes parameters, but 'getPrerenderParams' is missing. Please define 'getPrerenderParams' function for this route in your server routing configuration or specify a different 'renderMode'.
Minimal Reproduction
app.routes.ts
file with parameterng add @angular/ssr
ng build
Exception or Error
Your Environment
Anything else relevant?
Please note that I answered No to the following question when installing SSR, which is the default value:
The text was updated successfully, but these errors were encountered: