Returns (<A, B>(f) => ((a) => Fn<X, B>))
The mapped hom.
import { assertEquals } from "../deps.ts";
import { map } from "./func.ts";
const mapper = map<string>()((x: number) => x * 2);
assertEquals(mapper(parseInt)("20"), 40);
- <A, B>(f): ((a) => Fn<X, B>)
Returns ((a) => Fn<X, B>)
- (a): Fn<X, B>
Returns Fn<X, B>
Maps the hom
X => A
withf
.