Routing Angular Applications

Getting Started

We'll be using the Angular 2 starter kit we created for the Getting Started with Angular 2 course.

The starter kit does a lot of things for us like:

  • Bring in all the dependencies we need
  • Set up our dev environment
  • Compile TypeScript to JS
  • Load imports using System.js


Go ahead and fork the repo or clone it down.

git clone ng2-routing

Then we can install all our dependencies:

cd ng2-routing
npm install

Note: There may be some warnings for dependencies. All is still well.

Now we can start our app:

npm start

You can then see your app at http://localhost:3000. This will be our base for getting started.

We already have @angular/router installed in the package.json file and we have it ready to go.