import { R } from "https://deno.land/x/ahh@v0.10.3/mod.ts";
Return other
if res
is Ok
, or res
.
Examples
Example 1
Example 1
import { R } from "./mod.ts";
console.log(R.and(1, 2)); // 2
console.log(R.and(Error(), 2)); // Error()
console.log(R.and(2, Error())); // Error()
console.log(R.and(Error("a"), Error("b"))); // Error("a")