Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="angularjs 1.2.3 touch link with ng-click issue: correct with no ng-touch" />
<meta charset=utf-8 />
<title>JS Bin</title>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.3/angular.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.3/angular-touch.js"></script>
</head>
  <body ng-app="test">
  <div ng-controller="MyCtrl">
    <a href="#/qwer" ng-click="fff()">click me</a>
  </div>
</body>
</html>
 
var app = angular.module('test', [/*'ngTouch'*/]);
app.controller('MyCtrl', function MyCtrl($scope) {
  $scope.fff = function fff() {
    window.location.hash = '';
    console.log('hash cleared, must be empty:', window.location.hash);
    setTimeout(function () {
    console.log('hash must be "#/qwer" and it is:"', window.location.hash, '"');
    }, 500);
  };
});
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
bullgarepro
0viewers