-
Notifications
You must be signed in to change notification settings - Fork 27.4k
feat ngRepeat: add $even and $odd properties to iterator #3282
Conversation
There is something strange going on with the Travis build on Chrome: This does not fail for Firefox. Saw someone else's pull req (#3280) also had a Travis build fail like this one. Looks like neither of us touched anything that would upset Chrome, so we should look upstream probably? |
|
@npup Interesting.... What is your primary use-case for this change? What are the shortcommings of the existing directives (ng-class-odd / ng-class-even)? In any case this PR will need more work, I've included a checklist for you (see above). |
I've had the same test fail on a very simple change (#3297). |
@pkozlowski-opensource Hi, thanks for your answer! CLA was signed a few days ago, RL name: Petter Envall I think that not everything one could have valid reasons to alternate in an even/odd pattern is related to the The existing So my use cases for Some detail that popped up in my mind:
Not sure if there are idiomatic angularisms to avoid every situation that resembles what I touched on above. But having Regarding the PR checklist - as I said: not sure what was going on in Chrome (the newly checked out tree behaved like that in Chrome when building even without any modifications). And the commit message I thought would be ok. Cheers |
The travis error has been fixed in master. Try ammending the commit and forcing a new push. It will probably pass. |
This seems like a reasonable idea to me. |
Cool, build was fixed. Let's go ;) |
landed in 52b8211. Cheers! 🍺 |
When iterating, odd/even status is often nice to to have readily available in a
highly readable way.
These properties are not coupled to using CSS classes in the way of ngClassEven
and ngClassOdd directives.