Travis build: 1233

This commit is contained in:
30secondsofcode
2019-06-13 05:07:40 +00:00
parent 2b4eb72ff2
commit e970ed2d2c
5 changed files with 11 additions and 8 deletions

View File

@ -4503,10 +4503,10 @@ isSameDate(new Date(2010, 10, 20), new Date(2010, 10, 20)); // true
Returns the maximum of the given dates.
Use `Math.max.apply()` to find the maximum date value, `new Date()` to convert it to a `Date` object.
Use the ES6 spread syntax with `Math.max` to find the maximum date value, `new Date()` to convert it to a `Date` object.
```js
const maxDate = (...dates) => new Date(Math.max.apply(null, ...dates));
const maxDate = dates => new Date(Math.max(...dates));
```
<details>
@ -4530,10 +4530,10 @@ maxDate(array); // 2018-03-11T22:00:00.000Z
Returns the minimum of the given dates.
Use `Math.min.apply()` to find the minimum date value, `new Date()` to convert it to a `Date` object.
Use the ES6 spread syntax to find the minimum date value, `new Date()` to convert it to a `Date` object.
```js
const minDate = (...dates) => new Date(Math.min.apply(null, ...dates));
const minDate = dates => new Date(Math.min(...dates));
```
<details>
@ -4727,6 +4727,7 @@ const checkProp = (predicate, prop) => obj => !!predicate(obj[prop]);
```js
const lengthIs4 = checkProp(l => l === 4, 'length');
lengthIs4([]); // false
lengthIs4([1,2,3,4]); // true