marionettejs/backbone.marionette — pull request #481 by paulyoung (2013-02-19 17:27:19+00:00)
Title: Fixes #480: Passing index to ItemViewOptions when it is a function

This addresses the issue described in #480.

When `Marionette.CollectionView` is used without a model, there is no mechanism to provide dynamic data to each `ItemView` at runtime.

If a relevant and unique identifier was available, this could be acheived.

This solution passes the `index` of each `ItemView` to `ItemViewOptions` when it is a function.

The [provided spec](https://github.com/paulyoung/backbone.marionette/commit/e9309e4e4c37d850bbff39eaae0d43ba184bbff3) could potentially be combined with this [existing spec](https://github.com/paulyoung/backbone.marionette/blob/e9309e4e4c37d850bbff39eaae0d43ba184bbff3/spec/javascripts/collectionView.spec.js#L187-L190), however the existing spec was failing.