Travis build: 1676

This commit is contained in:
30secondsofcode
2018-02-14 11:55:14 +00:00
parent 7aaa55673c
commit 15d6b42d5b
3 changed files with 62 additions and 3 deletions

View File

@ -21,11 +21,11 @@ const mostPerformant = (fns, iterations = 10000) => {
mostPerformant([
() => {
// Loops through the entire array before returning `false`
[1, 2, 3, 4, 5, 6, 7, 8, 9, '10'].every(el => typeof el === 'number')
[1, 2, 3, 4, 5, 6, 7, 8, 9, '10'].every(el => typeof el === 'number');
},
() => {
// Only needs to reach index `1` before returning false
[1, '2', 3, 4, 5, 6, 7, 8, 9, 10].every(el => typeof el === 'number')
[1, '2', 3, 4, 5, 6, 7, 8, 9, 10].every(el => typeof el === 'number');
}
]); // 1
```