I have an issue, i want to add a css class to an item only if the browser isn't internet explorer.
Can I do that with Angular JS?
something like:
<div ng-class="myClass : "BROWSER IS IE" ? default"><div>
SOLUTION:
HTML:
<div data-ng-class="getClass()"></div>
JAVASCRIPT:
$scope.isIe = function () {
return false || !!document.documentMode;
}
$scope.getClass = function () {
if ($scope.isIe()) {
return "";
}
else {
return "yourClass1 yourClass2 yourClass3";
}
}