Permalink
Browse files

Merge pull request #1040 from braddunbar/$-docs

Fixes #1038 - Document changes to `view.$`.
  • Loading branch information...
2 parents a960794 + ef5835a commit 41e9d1a8479ba49ae9b43561229fd11c8b326934 @jashkenas jashkenas committed Feb 25, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 index.html
View
@@ -533,6 +533,11 @@ <h2 id="upgrading">Upgrading to 0.9</h2>
Similarly, after changing an attribute silently, that <tt>change:attribute</tt>
event <i>will</i> fire during the next change.
</li>
+ <li>
+ Since <tt>view.$(selector)</tt> is now equivalent to <tt>view.$el.find(selector)</tt>
+ rather than <tt>$(selector, view.el)</tt> it can no longer be used when
+ <tt>selector</tt> is an HTML string or DOM element.
+ </li>
</ul>
<h2 id="Events">Backbone.Events</h2>
@@ -2092,7 +2097,7 @@ <h2 id="View">Backbone.View</h2>
<b>$</b> function that runs queries scoped within the view's element. If you use this
scoped jQuery function, you don't have to use model ids as part of your query
to pull out specific elements in a list, and can rely much more on HTML class
- attributes. It's equivalent to running: <tt>$(selector, this.el)</tt>
+ attributes. It's equivalent to running: <tt>view.$el.find(selector)</tt>
</p>
<pre>

0 comments on commit 41e9d1a

Please sign in to comment.