clarify that sortBy is ascending.

This commit is contained in:
Jeremy Ashkenas
2012-01-23 16:10:49 -05:00
parent 5ed8b6e6ce
commit d959c019f8

View File

@@ -521,8 +521,8 @@ _.min(numbers);
<p id="sortBy"> <p id="sortBy">
<b class="header">sortBy</b><code>_.sortBy(list, iterator, [context])</code> <b class="header">sortBy</b><code>_.sortBy(list, iterator, [context])</code>
<br /> <br />
Returns a sorted copy of <b>list</b>, ranked by the results of running Returns a sorted copy of <b>list</b>, ranked in ascending order by the
each value through <b>iterator</b>. results of running each value through <b>iterator</b>.
</p> </p>
<pre> <pre>
_.sortBy([1, 2, 3, 4, 5, 6], function(num){ return Math.sin(num); }); _.sortBy([1, 2, 3, 4, 5, 6], function(num){ return Math.sin(num); });