Travis build: 872 [cron]
This commit is contained in:
64
dist/_30s.es5.js
vendored
64
dist/_30s.es5.js
vendored
@ -754,6 +754,9 @@
|
||||
return acc.concat(i > 1 ? acc[i - 1] + acc[i - 2] : i);
|
||||
}, []);
|
||||
};
|
||||
var filterFalsy = function filterFalsy(arr) {
|
||||
return arr.filter(Boolean);
|
||||
};
|
||||
var filterNonUnique = function filterNonUnique(arr) {
|
||||
return arr.filter(function (i) {
|
||||
return arr.indexOf(i) === arr.lastIndexOf(i);
|
||||
@ -1427,6 +1430,17 @@
|
||||
}, {});
|
||||
}, {});
|
||||
};
|
||||
var midpoint = function midpoint(_ref13, _ref14) {
|
||||
var _ref15 = _slicedToArray(_ref13, 2),
|
||||
x1 = _ref15[0],
|
||||
y1 = _ref15[1];
|
||||
|
||||
var _ref16 = _slicedToArray(_ref14, 2),
|
||||
x2 = _ref16[0],
|
||||
y2 = _ref16[1];
|
||||
|
||||
return [(x1 + x2) / 2, (y1 + y2) / 2];
|
||||
};
|
||||
var minBy = function minBy(arr, fn) {
|
||||
return Math.min.apply(Math, _toConsumableArray(arr.map(typeof fn === 'function' ? fn : function (val) {
|
||||
return val[fn];
|
||||
@ -1497,10 +1511,10 @@
|
||||
return (n === -1 ? arr.slice(n) : arr.slice(n, n + 1))[0];
|
||||
};
|
||||
var objectFromPairs = function objectFromPairs(arr) {
|
||||
return arr.reduce(function (a, _ref13) {
|
||||
var _ref14 = _slicedToArray(_ref13, 2),
|
||||
key = _ref14[0],
|
||||
val = _ref14[1];
|
||||
return arr.reduce(function (a, _ref17) {
|
||||
var _ref18 = _slicedToArray(_ref17, 2),
|
||||
key = _ref18[0],
|
||||
val = _ref18[1];
|
||||
|
||||
return a[key] = val, a;
|
||||
}, {});
|
||||
@ -1589,10 +1603,10 @@
|
||||
return _toConsumableArray(arr).sort(function (a, b) {
|
||||
return props.reduce(function (acc, prop, i) {
|
||||
if (acc === 0) {
|
||||
var _ref15 = orders && orders[i] === 'desc' ? [b[prop], a[prop]] : [a[prop], b[prop]],
|
||||
_ref16 = _slicedToArray(_ref15, 2),
|
||||
p1 = _ref16[0],
|
||||
p2 = _ref16[1];
|
||||
var _ref19 = orders && orders[i] === 'desc' ? [b[prop], a[prop]] : [a[prop], b[prop]],
|
||||
_ref20 = _slicedToArray(_ref19, 2),
|
||||
p1 = _ref20[0],
|
||||
p2 = _ref20[1];
|
||||
|
||||
acc = p1 > p2 ? 1 : p1 < p2 ? -1 : 0;
|
||||
}
|
||||
@ -1970,8 +1984,8 @@
|
||||
type: 'application/javascript; charset=utf-8'
|
||||
}));
|
||||
return new Promise(function (res, rej) {
|
||||
worker.onmessage = function (_ref17) {
|
||||
var data = _ref17.data;
|
||||
worker.onmessage = function (_ref21) {
|
||||
var data = _ref21.data;
|
||||
res(data), worker.terminate();
|
||||
};
|
||||
|
||||
@ -1988,18 +2002,18 @@
|
||||
var sample = function sample(arr) {
|
||||
return arr[Math.floor(Math.random() * arr.length)];
|
||||
};
|
||||
var sampleSize = function sampleSize(_ref18) {
|
||||
var _ref19 = _toArray(_ref18),
|
||||
arr = _ref19.slice(0);
|
||||
var sampleSize = function sampleSize(_ref22) {
|
||||
var _ref23 = _toArray(_ref22),
|
||||
arr = _ref23.slice(0);
|
||||
|
||||
var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
|
||||
var m = arr.length;
|
||||
|
||||
while (m) {
|
||||
var i = Math.floor(Math.random() * m--);
|
||||
var _ref20 = [arr[i], arr[m]];
|
||||
arr[m] = _ref20[0];
|
||||
arr[i] = _ref20[1];
|
||||
var _ref24 = [arr[i], arr[m]];
|
||||
arr[m] = _ref24[0];
|
||||
arr[i] = _ref24[1];
|
||||
}
|
||||
|
||||
return arr.slice(0, n);
|
||||
@ -2046,17 +2060,17 @@
|
||||
return e.style.display = '';
|
||||
});
|
||||
};
|
||||
var shuffle = function shuffle(_ref21) {
|
||||
var _ref22 = _toArray(_ref21),
|
||||
arr = _ref22.slice(0);
|
||||
var shuffle = function shuffle(_ref25) {
|
||||
var _ref26 = _toArray(_ref25),
|
||||
arr = _ref26.slice(0);
|
||||
|
||||
var m = arr.length;
|
||||
|
||||
while (m) {
|
||||
var i = Math.floor(Math.random() * m--);
|
||||
var _ref23 = [arr[i], arr[m]];
|
||||
arr[m] = _ref23[0];
|
||||
arr[i] = _ref23[1];
|
||||
var _ref27 = [arr[i], arr[m]];
|
||||
arr[m] = _ref27[0];
|
||||
arr[i] = _ref27[1];
|
||||
}
|
||||
|
||||
return arr;
|
||||
@ -2130,8 +2144,8 @@
|
||||
};
|
||||
}).sort(function (a, b) {
|
||||
return compare(a.item, b.item) || a.index - b.index;
|
||||
}).map(function (_ref24) {
|
||||
var item = _ref24.item;
|
||||
}).map(function (_ref28) {
|
||||
var item = _ref28.item;
|
||||
return item;
|
||||
});
|
||||
};
|
||||
@ -2656,6 +2670,7 @@
|
||||
exports.extendHex = extendHex;
|
||||
exports.factorial = factorial;
|
||||
exports.fibonacci = fibonacci;
|
||||
exports.filterFalsy = filterFalsy;
|
||||
exports.filterNonUnique = filterNonUnique;
|
||||
exports.filterNonUniqueBy = filterNonUniqueBy;
|
||||
exports.findKey = findKey;
|
||||
@ -2766,6 +2781,7 @@
|
||||
exports.median = median;
|
||||
exports.memoize = memoize;
|
||||
exports.merge = merge;
|
||||
exports.midpoint = midpoint;
|
||||
exports.minBy = minBy;
|
||||
exports.minDate = minDate;
|
||||
exports.minN = minN;
|
||||
|
||||
2
dist/_30s.es5.min.js
vendored
2
dist/_30s.es5.min.js
vendored
File diff suppressed because one or more lines are too long
10
dist/_30s.esm.js
vendored
10
dist/_30s.esm.js
vendored
@ -327,6 +327,7 @@ const fibonacci = n =>
|
||||
(acc, val, i) => acc.concat(i > 1 ? acc[i - 1] + acc[i - 2] : i),
|
||||
[]
|
||||
);
|
||||
const filterFalsy = arr => arr.filter(Boolean);
|
||||
const filterNonUnique = arr => arr.filter(i => arr.indexOf(i) === arr.lastIndexOf(i));
|
||||
const filterNonUniqueBy = (arr, fn) =>
|
||||
arr.filter((v, i) => arr.every((x, j) => (i === j) === fn(v, x, i, j)));
|
||||
@ -710,6 +711,7 @@ const merge = (...objs) =>
|
||||
}, {}),
|
||||
{}
|
||||
);
|
||||
const midpoint = ([x1, y1], [x2, y2]) => [(x1 + x2) / 2, (y1 + y2) / 2];
|
||||
const minBy = (arr, fn) => Math.min(...arr.map(typeof fn === 'function' ? fn : val => val[fn]));
|
||||
const minDate = (...dates) => new Date(Math.min.apply(null, ...dates));
|
||||
const minN = (arr, n = 1) => [...arr].sort((a, b) => a - b).slice(0, n);
|
||||
@ -960,9 +962,9 @@ const reject = (pred, array) => array.filter((...args) => !pred(...args));
|
||||
const remove = (arr, func) =>
|
||||
Array.isArray(arr)
|
||||
? arr.filter(func).reduce((acc, val) => {
|
||||
arr.splice(arr.indexOf(val), 1);
|
||||
return acc.concat(val);
|
||||
}, [])
|
||||
arr.splice(arr.indexOf(val), 1);
|
||||
return acc.concat(val);
|
||||
}, [])
|
||||
: [];
|
||||
const removeNonASCII = str => str.replace(/[^\x20-\x7E]/g, '');
|
||||
const renameKeys = (keysMap, obj) =>
|
||||
@ -1321,4 +1323,4 @@ const zipWith = (...array) => {
|
||||
);
|
||||
};
|
||||
|
||||
export { CSVToArray, CSVToJSON, JSONToFile, JSONtoCSV, RGBToHex, URLJoin, UUIDGeneratorBrowser, UUIDGeneratorNode, all, allEqual, any, approximatelyEqual, arrayToCSV, arrayToHtmlList, ary, atob, attempt, average, averageBy, bifurcate, bifurcateBy, bind, bindAll, bindKey, binomialCoefficient, bottomVisible, btoa, byteSize, call, capitalize, capitalizeEveryWord, castArray, chainAsync, chunk, clampNumber, cloneRegExp, coalesce, coalesceFactory, collectInto, colorize, compact, compose, composeRight, converge, copyToClipboard, countBy, countOccurrences, counter, createElement, createEventHub, currentURL, curry, dayOfYear, debounce, decapitalize, deepClone, deepFlatten, deepFreeze, defaults, defer, degreesToRads, delay, detectDeviceType, difference, differenceBy, differenceWith, dig, digitize, distance, drop, dropRight, dropRightWhile, dropWhile, elementContains, elementIsVisibleInViewport, elo, equals, escapeHTML, escapeRegExp, everyNth, extendHex, factorial, fibonacci, filterNonUnique, filterNonUniqueBy, findKey, findLast, findLastIndex, findLastKey, flatten, flattenObject, flip, forEachRight, forOwn, forOwnRight, formatDuration, fromCamelCase, functionName, functions, gcd, geometricProgression, get, getColonTimeFromDate, getDaysDiffBetweenDates, getImages, getMeridiemSuffixOfInteger, getScrollPosition, getStyle, getType, getURLParameters, groupBy, hammingDistance, hasClass, hasFlags, hashBrowser, hashNode, head, hexToRGB, hide, httpGet, httpPost, httpsRedirect, hz, inRange, indentString, indexOfAll, initial, initialize2DArray, initializeArrayWithRange, initializeArrayWithRangeRight, initializeArrayWithValues, initializeNDArray, insertAfter, insertBefore, intersection, intersectionBy, intersectionWith, invertKeyValues, is, isAbsoluteURL, isAfterDate, isAnagram, isArrayLike, isBeforeDate, isBoolean, isBrowser, isBrowserTabFocused, isDivisible, isDuplexStream, isEmpty, isEven, isFunction, isLowerCase, isNegativeZero, isNil, isNull, isNumber, isObject, isObjectLike, isPlainObject, isPrime, isPrimitive, isPromiseLike, isReadableStream, isSameDate, isSorted, isStream, isString, isSymbol, isTravisCI, isUndefined, isUpperCase, isValidJSON, isWritableStream, join, last, lcm, longestItem, lowercaseKeys, luhnCheck, mapKeys, mapObject, mapString, mapValues, mask, matches, matchesWith, maxBy, maxDate, maxN, median, memoize, merge, minBy, minDate, minN, mostPerformant, negate, nest, nodeListToArray, none, nthArg, nthElement, objectFromPairs, objectToPairs, observeMutations, off, offset, omit, omitBy, on, onUserInputChange, once, orderBy, over, overArgs, pad, palindrome, parseCookie, partial, partialRight, partition, percentile, permutations, pick, pickBy, pipeAsyncFunctions, pipeFunctions, pluralize, powerset, prefix, prettyBytes, primes, promisify, pull, pullAtIndex, pullAtValue, pullBy, radsToDegrees, randomHexColorCode, randomIntArrayInRange, randomIntegerInRange, randomNumberInRange, readFileLines, rearg, recordAnimationFrames, redirect, reduceSuccessive, reduceWhich, reducedFilter, reject, remove, removeNonASCII, renameKeys, reverseString, round, runAsync, runPromisesInSeries, sample, sampleSize, scrollToTop, sdbm, serializeCookie, setStyle, shallowClone, shank, show, shuffle, similarity, size, sleep, smoothScroll, sortCharactersInString, sortedIndex, sortedIndexBy, sortedLastIndex, sortedLastIndexBy, splitLines, spreadOver, stableSort, standardDeviation, stringPermutations, stripHTMLTags, sum, sumBy, sumPower, symmetricDifference, symmetricDifferenceBy, symmetricDifferenceWith, tail, take, takeRight, takeRightWhile, takeWhile, throttle, timeTaken, times, toCamelCase, toCurrency, toDecimalMark, toHash, toKebabCase, toOrdinalSuffix, toSafeInteger, toSnakeCase, toTitleCase, toggleClass, tomorrow, transform, triggerEvent, truncateString, truthCheckCollection, unary, uncurry, unescapeHTML, unflattenObject, unfold, union, unionBy, unionWith, uniqueElements, uniqueElementsBy, uniqueElementsByRight, uniqueSymmetricDifference, untildify, unzip, unzipWith, validateNumber, when, without, words, xProd, yesNo, zip, zipObject, zipWith };
|
||||
export { CSVToArray, CSVToJSON, JSONToFile, JSONtoCSV, RGBToHex, URLJoin, UUIDGeneratorBrowser, UUIDGeneratorNode, all, allEqual, any, approximatelyEqual, arrayToCSV, arrayToHtmlList, ary, atob, attempt, average, averageBy, bifurcate, bifurcateBy, bind, bindAll, bindKey, binomialCoefficient, bottomVisible, btoa, byteSize, call, capitalize, capitalizeEveryWord, castArray, chainAsync, chunk, clampNumber, cloneRegExp, coalesce, coalesceFactory, collectInto, colorize, compact, compose, composeRight, converge, copyToClipboard, countBy, countOccurrences, counter, createElement, createEventHub, currentURL, curry, dayOfYear, debounce, decapitalize, deepClone, deepFlatten, deepFreeze, defaults, defer, degreesToRads, delay, detectDeviceType, difference, differenceBy, differenceWith, dig, digitize, distance, drop, dropRight, dropRightWhile, dropWhile, elementContains, elementIsVisibleInViewport, elo, equals, escapeHTML, escapeRegExp, everyNth, extendHex, factorial, fibonacci, filterFalsy, filterNonUnique, filterNonUniqueBy, findKey, findLast, findLastIndex, findLastKey, flatten, flattenObject, flip, forEachRight, forOwn, forOwnRight, formatDuration, fromCamelCase, functionName, functions, gcd, geometricProgression, get, getColonTimeFromDate, getDaysDiffBetweenDates, getImages, getMeridiemSuffixOfInteger, getScrollPosition, getStyle, getType, getURLParameters, groupBy, hammingDistance, hasClass, hasFlags, hashBrowser, hashNode, head, hexToRGB, hide, httpGet, httpPost, httpsRedirect, hz, inRange, indentString, indexOfAll, initial, initialize2DArray, initializeArrayWithRange, initializeArrayWithRangeRight, initializeArrayWithValues, initializeNDArray, insertAfter, insertBefore, intersection, intersectionBy, intersectionWith, invertKeyValues, is, isAbsoluteURL, isAfterDate, isAnagram, isArrayLike, isBeforeDate, isBoolean, isBrowser, isBrowserTabFocused, isDivisible, isDuplexStream, isEmpty, isEven, isFunction, isLowerCase, isNegativeZero, isNil, isNull, isNumber, isObject, isObjectLike, isPlainObject, isPrime, isPrimitive, isPromiseLike, isReadableStream, isSameDate, isSorted, isStream, isString, isSymbol, isTravisCI, isUndefined, isUpperCase, isValidJSON, isWritableStream, join, last, lcm, longestItem, lowercaseKeys, luhnCheck, mapKeys, mapObject, mapString, mapValues, mask, matches, matchesWith, maxBy, maxDate, maxN, median, memoize, merge, midpoint, minBy, minDate, minN, mostPerformant, negate, nest, nodeListToArray, none, nthArg, nthElement, objectFromPairs, objectToPairs, observeMutations, off, offset, omit, omitBy, on, onUserInputChange, once, orderBy, over, overArgs, pad, palindrome, parseCookie, partial, partialRight, partition, percentile, permutations, pick, pickBy, pipeAsyncFunctions, pipeFunctions, pluralize, powerset, prefix, prettyBytes, primes, promisify, pull, pullAtIndex, pullAtValue, pullBy, radsToDegrees, randomHexColorCode, randomIntArrayInRange, randomIntegerInRange, randomNumberInRange, readFileLines, rearg, recordAnimationFrames, redirect, reduceSuccessive, reduceWhich, reducedFilter, reject, remove, removeNonASCII, renameKeys, reverseString, round, runAsync, runPromisesInSeries, sample, sampleSize, scrollToTop, sdbm, serializeCookie, setStyle, shallowClone, shank, show, shuffle, similarity, size, sleep, smoothScroll, sortCharactersInString, sortedIndex, sortedIndexBy, sortedLastIndex, sortedLastIndexBy, splitLines, spreadOver, stableSort, standardDeviation, stringPermutations, stripHTMLTags, sum, sumBy, sumPower, symmetricDifference, symmetricDifferenceBy, symmetricDifferenceWith, tail, take, takeRight, takeRightWhile, takeWhile, throttle, timeTaken, times, toCamelCase, toCurrency, toDecimalMark, toHash, toKebabCase, toOrdinalSuffix, toSafeInteger, toSnakeCase, toTitleCase, toggleClass, tomorrow, transform, triggerEvent, truncateString, truthCheckCollection, unary, uncurry, unescapeHTML, unflattenObject, unfold, union, unionBy, unionWith, uniqueElements, uniqueElementsBy, uniqueElementsByRight, uniqueSymmetricDifference, untildify, unzip, unzipWith, validateNumber, when, without, words, xProd, yesNo, zip, zipObject, zipWith };
|
||||
|
||||
10
dist/_30s.js
vendored
10
dist/_30s.js
vendored
@ -333,6 +333,7 @@
|
||||
(acc, val, i) => acc.concat(i > 1 ? acc[i - 1] + acc[i - 2] : i),
|
||||
[]
|
||||
);
|
||||
const filterFalsy = arr => arr.filter(Boolean);
|
||||
const filterNonUnique = arr => arr.filter(i => arr.indexOf(i) === arr.lastIndexOf(i));
|
||||
const filterNonUniqueBy = (arr, fn) =>
|
||||
arr.filter((v, i) => arr.every((x, j) => (i === j) === fn(v, x, i, j)));
|
||||
@ -716,6 +717,7 @@
|
||||
}, {}),
|
||||
{}
|
||||
);
|
||||
const midpoint = ([x1, y1], [x2, y2]) => [(x1 + x2) / 2, (y1 + y2) / 2];
|
||||
const minBy = (arr, fn) => Math.min(...arr.map(typeof fn === 'function' ? fn : val => val[fn]));
|
||||
const minDate = (...dates) => new Date(Math.min.apply(null, ...dates));
|
||||
const minN = (arr, n = 1) => [...arr].sort((a, b) => a - b).slice(0, n);
|
||||
@ -966,9 +968,9 @@
|
||||
const remove = (arr, func) =>
|
||||
Array.isArray(arr)
|
||||
? arr.filter(func).reduce((acc, val) => {
|
||||
arr.splice(arr.indexOf(val), 1);
|
||||
return acc.concat(val);
|
||||
}, [])
|
||||
arr.splice(arr.indexOf(val), 1);
|
||||
return acc.concat(val);
|
||||
}, [])
|
||||
: [];
|
||||
const removeNonASCII = str => str.replace(/[^\x20-\x7E]/g, '');
|
||||
const renameKeys = (keysMap, obj) =>
|
||||
@ -1410,6 +1412,7 @@
|
||||
exports.extendHex = extendHex;
|
||||
exports.factorial = factorial;
|
||||
exports.fibonacci = fibonacci;
|
||||
exports.filterFalsy = filterFalsy;
|
||||
exports.filterNonUnique = filterNonUnique;
|
||||
exports.filterNonUniqueBy = filterNonUniqueBy;
|
||||
exports.findKey = findKey;
|
||||
@ -1520,6 +1523,7 @@
|
||||
exports.median = median;
|
||||
exports.memoize = memoize;
|
||||
exports.merge = merge;
|
||||
exports.midpoint = midpoint;
|
||||
exports.minBy = minBy;
|
||||
exports.minDate = minDate;
|
||||
exports.minN = minN;
|
||||
|
||||
Reference in New Issue
Block a user