SIGN IN SIGN UP
angular / angular.js UNCLAIMED

AngularJS - HTML enhanced for web apps!

0 0 0 JavaScript

feat(ngClass): add support for conditional map within an array.

This change allows `ngClass` expressions to have both objects and strings
within an array:

```js
$scope.classVar = 'nav-item';
$scope.activeVar = true;
```

```html
<div ng-class=" [classVar, {'is-active': activeVar }] ">
```

In this case, the CSS classes that will be added are: 'nav-item' and 'is-active'.

Closes #4807
B
Bob Fanger committed
4588e627bb7238b2113241919b948d0e5166c76d
Parent: ea9fd82
Committed by Peter Bacon Darwin <pete@bacondarwin.com> on 3/18/2015, 11:17:44 AM