Angular1: Empty Fiddle

HTML

<div ng-app="app">
  <div ng-controller="TestingCtrl as vm">
    <h2>{{vm.title}}</h2>
    <span class="fa fa-remove fa-lg text-danger" style="cursor: pointer;"
                    ng-show="location.isEdit"
                    ng-click="readOnly===false && (vm.cancel(), location.isEdit = false, updateClicked = false)"></span>
  </div>
</div>

JavaScript

angular.module('app', [])

.controller('TestingCtrl', [function TestingCtrl($scope) {
	var vm = this;
  vm.title = 'Angular 1 testing';
  vm.cancel = () => console.log("ciao")
}])