walmartlabs/thorax — pull request #312 by ryan-roemer (2014-01-31 19:40:39+00:00)
Title: Always return 'this' from Thorax.View.render().

Backbone's `view.render()` says:

```js
// **render** is the core function that your view should override, in order
// to populate its element (`this.el`), with the appropriate HTML. The
// convention is for **render** to always return `this`.
render: function() {
return this;
},
```

However, `Thorax.View.render()` returns `undefined` if there is no `view.el` and the `output` parameter passed to `render()` in the other case. This PR switches both cases to return `this` per the Backbone way.

**Note**: This is technically a breaking change for anyone who relied on `output` being passed pack in a chain of some sort. I believe that behavior is completely undocumented, but I'm not sure what the expectations are in that regard.

/cc @kpdecker @eastridge