Created
April 20, 2018 15:33
-
-
Save wholypantalones/815afec22389f99f8de4a45f615f0e30 to your computer and use it in GitHub Desktop.
Angularjs route params
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var lastRoute = $route.current; | |
console.log(lastRoute); | |
$scope.$on('$locationChangeSuccess', function (event) { | |
if (lastRoute.$$route.originalPath === $route.current.$$route.originalPath) { | |
$route.current = lastRoute; | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment