Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
chain-able-deps / dist / math / max.js
Size: Mime:
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var curry_1 = require("../fp/curry");
/**
 * Returns the larger of its two arguments.
 * @since 5.0.0-beta.6
 * @name max
 * @alias biggest
 * @memberOf math
 *
 * @param {number|*} a
 * @param {number|*} b
 * @return {number|*} if (b > a) b; else b
 *
 * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/max mozilla-math.max}
 * @see {@link mozilla-math.max}
 *
 * @TODO add maxAll for `reduce(max)`
 *
 * @func
 * @fork v0.1.0
 * @category Relation
 * @sig Ord a => a -> a -> a
 *
 * @see maxBy, min
 * @see math/min
 *
 * @example
 *
 *      max(789, 123); //=> 789
 *      max('a', 'b'); //=> 'b'
 *
 */
function max(a, b) {
    return b > a ? b : a;
}
exports.default = curry_1.default(2, max);
//# sourceMappingURL=max.js.map