Angular2: Error – No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.

Standard

If you receive below error while working on Angular2 application:

No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.

screenshot_6

Solution is try to include <base> tag inside your index.html page or master layout page.

<base href="/">

screenshot_2

Advertisements

One thought on “Angular2: Error – No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.

  1. Adil

    Thank for sharing the valuable information about Angular 2.0. I have learnt lot from your site. Could you give any GRID example implanted in Angular 2.0 using Visual Studio 2015 ( but that should not be .net Core).

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s