Angular route not matching with hash

Solution 1:

You can use href="javascript:void(0)" on your href so it will stop the redirect or you can use onclick="return false".

Example 1

<a href="javascript:void(0)">link</a>

Example 2

<a href="" onclick="return false;">link</a>