An Angular application runs as a SPA (Single Page Application). The first page loaded, usually index.html is displayed and on a simple application will never be changed. Inside this page the root component is loaded, in our case app.component is shown. So how do we change pages?
In the traditional browser setup as we navigate from page to page a completely new page is requested with a http request to the serve. In a SPA only part of the page which has new content is updated by replacing the root component with another component.The SPA has many advantages over the traditional setup.
- New pages are generated with partial page updates
- Serve traffic is reduced
- The application becomes more responsive
How this is done is the subject of routing and navigation.