Skip to content

Commit

Permalink
Merge pull request #2978 from stevenh/fix/range-step-docs
Browse files Browse the repository at this point in the history
fix(range): step documentation
  • Loading branch information
jgonggrijp authored Nov 29, 2022
2 parents 7860d11 + 383d9fa commit d122213
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1463,12 +1463,10 @@ <h2 id="arrays">Array Functions</h2>
<br />
A function to create flexibly-numbered lists of integers, handy for
<tt>each</tt> and <tt>map</tt> loops. <b>start</b>, if omitted,
defaults to <i>0</i>; <b>step</b> defaults to <i>1</i>. Returns a list
defaults to <i>0</i>; <b>step</b> defaults to <i>1</i> if <b>start</b>
is before <b>stop</b>, otherwise <i>-1</i>. Returns a list
of integers from <b>start</b> (inclusive) to <b>stop</b> (exclusive),
incremented (or decremented) by <b>step</b>. Note that ranges that
<b>stop</b> before they <b>start</b> are considered to be zero-length
instead of negative — if you'd like a negative range, use a negative
<b>step</b>.
incremented (or decremented) by <b>step</b>.
</p>
<pre>
_.range(10);
Expand Down

0 comments on commit d122213

Please sign in to comment.