Now that we have our app routed, we just need to create links over to those pages.

Instead of using <a href="/about">About</a>, we'll use the Angular 2 router way of linking to different routes:

<a routerLink="/about">About</a>

The router uses the HTML5 History API so that each page we navigate to will be part of the history.

Table of Contents

    Also, unlike Angular 1, we aren't using the hashbang way of routing (ie http://localhost:3000/#/about).

    By default, we will be using HTML5 push-state.

    Chris Sevilleja

    173 posts

    Co-founder of Slapping the keyboard until something good happens.