{"version":3,"file":"either.mjs","sources":["../../../../node_modules/ramda/es/either.js"],"sourcesContent":["import _curry2 from \"./internal/_curry2.js\";\nimport _isFunction from \"./internal/_isFunction.js\";\nimport lift from \"./lift.js\";\nimport or from \"./or.js\";\n/**\n * A function wrapping calls to the two functions in an `||` operation,\n * returning the result of the first function if it is truth-y and the result\n * of the second function otherwise. Note that this is short-circuited,\n * meaning that the second function will not be invoked if the first returns a\n * truth-y value.\n *\n * In addition to functions, `R.either` also accepts any fantasy-land compatible\n * applicative functor.\n *\n * @func\n * @memberOf R\n * @since v0.12.0\n * @category Logic\n * @sig (*... -> Boolean) -> (*... -> Boolean) -> (*... -> Boolean)\n * @param {Function} f a predicate\n * @param {Function} g another predicate\n * @return {Function} a function that applies its arguments to `f` and `g` and `||`s their outputs together.\n * @see R.or\n * @example\n *\n *      const gt10 = x => x > 10;\n *      const even = x => x % 2 === 0;\n *      const f = R.either(gt10, even);\n *      f(101); //=> true\n *      f(8); //=> true\n *\n *      R.either(Maybe.Just(false), Maybe.Just(55)); // => Maybe.Just(55)\n *      R.either([false, false, 'a'], [11]) // => [11, 11, \"a\"]\n */\n\nvar either =\n/*#__PURE__*/\n_curry2(function either(f, g) {\n  return _isFunction(f) ? function _either() {\n    return f.apply(this, arguments) || g.apply(this, arguments);\n  } : lift(or)(f, g);\n});\n\nexport default either;"],"names":[],"mappings":";;;;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEG,IAAC,MAAM;AACV;AACA,OAAO,CAAC,SAAS,MAAM,CAAC,CAAC,EAAE,CAAC,EAAE;AAC9B,EAAE,OAAO,WAAW,CAAC,CAAC,CAAC,GAAG,SAAS,OAAO,GAAG;AAC7C,IAAI,OAAO,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,SAAS,CAAC;AAC/D,EAAE,CAAC,GAAG,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;AACpB,CAAC;;;;","x_google_ignoreList":[0]}