Reputation: 398
While defining routes in angular 2 if I don't define wildcard route and try to hit an invalid url that doesn't exists. What will be the response?
Upvotes: 0
Views: 50
Reputation: 8613
You will most likely get the following error if you call such a URL:
Error: Cannot match any routes. URL Segment: 'my-invalid-url' Error: Cannot match any routes.
And the application remains on the page that was loaded successfully most recently.
Upvotes: 1