Angular 17 Prerendering Static Site Generation (SSG) | Prerendering parameterized routes
How to prerender a page in Angular
17?
Prerendering, commonly called Static Site Generation (SSG), represents how pages are rendered to static HTML files during the build process.
To prerender a static page, add SSR capabilities to your application with the following Angular CLI command: ng add @angular/ssr
To create an application with prerendering capabilities from the beginning use the Angular CLI command: ng new --ssr
Once SSR is added, you can
generate the static pages by running the build command: ng build
Why use SSG?
Improved performance: SSR can
improve the performance of web applications by delivering fully rendered HTML
to the client, which the browser can parse and display even before it downloads
the application JavaScript.
Better SEO: SSR can improve the
search engine optimization (SEO) of web applications by making it easier for
search engines to crawl and index the application's content.
This is the YouTube video link for this - https://youtu.be/8b8deVyk3pw