Last change
on this file since eed0bf8 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
390 bytes
|
Rev | Line | |
---|
[6a3a178] | 1 | /**
|
---|
| 2 | * This method returns a new empty array.
|
---|
| 3 | *
|
---|
| 4 | * @static
|
---|
| 5 | * @memberOf _
|
---|
| 6 | * @since 4.13.0
|
---|
| 7 | * @category Util
|
---|
| 8 | * @returns {Array} Returns the new empty array.
|
---|
| 9 | * @example
|
---|
| 10 | *
|
---|
| 11 | * var arrays = _.times(2, _.stubArray);
|
---|
| 12 | *
|
---|
| 13 | * console.log(arrays);
|
---|
| 14 | * // => [[], []]
|
---|
| 15 | *
|
---|
| 16 | * console.log(arrays[0] === arrays[1]);
|
---|
| 17 | * // => false
|
---|
| 18 | */
|
---|
| 19 | function stubArray() {
|
---|
| 20 | return [];
|
---|
| 21 | }
|
---|
| 22 |
|
---|
| 23 | module.exports = stubArray;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.