marionettejs/backbone.marionette — pull request #1754 by jasonLaster (2014-08-23 01:23:53+00:00)
Title: Update jsdoc grunt task to accomadate function values with examples

The new helpers.jsdoc file has function examples, which are really cool and we should support.

They look something like this:

```yaml
actAsCollection:
description: |
Mix in methods from Underscore, for iteration, and other collection related features. Borrowing this code
from `Backbone.Collection`. See http://backbonejs.org/docs/backbone.html#section-121

@api public
@static
@param {Object} object
@param {Object} listProperty

examples:
-
name: Object Literal
example: |
It works by taking an object and a property field, in this example 'list',
and appending collection functions to the object so that it can
delegate collection calls to its list.

```js
var obj = {
list: [1, 2, 3]
}

Marionette.actAsCollection(obj, 'list');

var double = function(v){ return v*2};
console.log(obj.map(double)); // [2, 4, 6]
```

-
name: Function Prototype
example: |
```js
var Func = function(list) {
this.list = list;
};

Marionette.actAsCollection(Func.prototype, 'list');
var func = new Func([1,2,3]);

var double = function(v){ return v*2};
console.log(func.map(double)); // [2, 4, 6]
```
````