Add item to _.fill example. [ci skip]

While not the minimum example required to show the fill functionality, having the fill write more than one value better fits the purpose of the function in practice.
This commit is contained in:
MaxPRafferty
2015-08-21 14:49:03 -04:00
committed by John-David Dalton
parent e253fe0547
commit 00bae752d0

View File

@@ -4493,8 +4493,8 @@
* _.fill(Array(3), 2);
* // => [2, 2, 2]
*
* _.fill([4, 6, 8], '*', 1, 2);
* // => [4, '*', 8]
* _.fill([4, 6, 8, 10], '*', 1, 3);
* // => [4, '*', '*', 10]
*/
function fill(array, value, start, end) {
var length = array ? array.length : 0;