Martin Schagerl
Martin Schagerl

Reputation: 613

Angular CLI - After refreshing in browser the browser try to load files from a wrong location

I have an Angular CLI application. If I navigate to an specific route and then trigger a refresh (F5 in the Browser), the browser try to load files from a wrong location.

enter image description here

So is it possible to define in the .angular-cli.json a base path? Or whats the right way here?

Thanks!

UPDATE: If I add the following statement to the .angular-cli.json, the .js file will be loaded correctly. But fonts (e.g. ttf, woff, ...) will be loaded from the wrong location

"apps": [
{
    "baseHref": "/"
}]

Upvotes: 0

Views: 164

Answers (1)

Martin Schagerl
Martin Schagerl

Reputation: 613

The problem was in the dev version, because I use angular/cli@next: Github - AOT build error Cannot read property 'kind' of undefined

Upvotes: 1

Related Questions