View source Improve this doc

ngClassEven
directive in module ng

Description

The ngClassOdd and ngClassEven directives work exactly as ngClass, except they work in conjunction with ngRepeat and take effect only on odd (even) rows.

This directive can be applied only within the scope of an ngRepeat.

Usage

as attribute
<ANY ng-class-even="{expression}">
   ...
</ANY>
as class
<ANY class="ng-class-even: {expression};">
   ...
</ANY>

Parameters

ParamTypeDetails
ngClassEvenexpression

Expression to eval. The result of the evaluation can be a string representing space delimited class names or an array.

Example

Source







Demo