1
我的目标是在angularjs控制器上获得true如果URL为#how htttp://www.example.com#how
或false如果url没有#how。Angularjs检查或网址上存在
webApp.controller('ctrl',function($scope){
$scope.showHow = ???; // if url with #how == true else false
...
使用Angular的'$ window'服务通常更好的做法是 – Ankh