-
Notifications
You must be signed in to change notification settings - Fork 27.4k
Router functionality broken from 1.3.5 to 1.3.6 in some specific cases #11693
Comments
It seems to work for me with v1.3.6. Also tested with v1.3.15 and v1.4.0-rc.0 and works as expected. @machacz, it might be something else. Could you provide a live reproduction of the issue ? |
http://angular.softnauts.com/szablony_routingi/index.html Click on Test once, clik on other link, click on Test again. |
There seems to be indeed some problem here. I can't get to the root of the problem - that Known facts about the issue:
Should anyone be interested, the issue can be reproduced in this codepen with the following steps:
Expected behaviour: Observed behaviour: After step (3), clicking on the link again seems to have no effect (no change in location or route). In order to gain some insight on what's going on, I tried logging the $location- and $route-related events (which can be seen in section
The 4th entry seems particularly odd. I would expect a Sorry for the long post. Let's hope it will be helpful to someone 😄 |
List of commits between v1.3.5 and v1.3.6 (for easy reference). |
This also appears to cause http://jsbin.com/momidogike/1/edit?html,js,output I had a look at the commits in @gkalpak's list above and I think the problematic one is 10ac594. Reverting this commit appears to resolve the issue (JSBin output with patched Angular version - http://output.jsbin.com/mapizutoco/1#/) |
I can confirm that using @richardTowers's patched version, fixes the original issue as well. |
to @petebacondarwin that is the |
I believe that the reason that this does not "fail" in 1.3.5 is that the browser was always doing a full reload when we go to the Test3 route. You can see this happening if you run the CodePen with 1.3.5. After the 10ac594 commit we no longer reload when only the hash is removed from the url and so it appears that we can now see this issue. I would argue that the issue existed before too but that it was not apparent due to the reload hiding it. |
This seems to have been fixed since at least 1.5.0: Updated pen (Please re-open if you still see the issue.) code.angularjs.org/1.5.6 |
HTML code (outside ng-app):
JavaScript:
The issue: Clicking on 'Test' should result in default action to be performed, and that's how it is up to 1.3.5. In 1.3.6 and above nothing happenes instead - I can see white screen only. Clicking on first three links works as it should.
The text was updated successfully, but these errors were encountered: