The !
is the normal negation operator.
Inside of that function, it’s used to flip/toggle the value each time it’s called. For example, from true
to false
and vice-versa.
2
solved what does the ! mean in Angular? i.e $scope.selected = !$scope.selected; [duplicate]