IE9 (and 8?) reloads page on link with ng-click if $location is injected #1179
Description
As discussed here on google groups, Leo Cavalcante points out that when the $location dependency is injected, IE8-9 acts strangely and somehow reloads the page, instead of preventing the default action as is expected on a click on an anchor with the ng-click directive. I forked his fiddle and made another one which shows the problem in a more obvious way:
On initial run, the value in the textbox is 'initial', then after the click on the link it gets changed to 'test', but is reverted back to 'initial' automatically because of this bug. If we remove the $location dependency and re-run the fiddle, it works as expected. I don't have IE8, but I have this problem on IE9 / Win7.
Hopefully this is not a duplicate, I did check the issues marked as bugs and did not find this.
Martin
EDIT: This is with AngularJS 1.0.1 by the way, as can be seen in the fiddle.