documentcloud/backbone — pull request #909 by josscrowcroft (2012-01-31 09:23:27+00:00)
Title: Return `this` from View.setElement()

Love the new `setElement` method - replaces a bunch of cruft in our application with one simple call whenever a View is reused.

One tiny change I made is to return the View (`this`) from the method so that I can go e.g.:

```javascript
myView.setElement('#element').render();
```

...instead of making those two calls separately.

Seems like a logical addition to me and I couldn't see a solid reason for not returning anything from the method, correct me if I'm wrong.

Thanks!