Skip to content

map

map<A, B>(f): (s) => ReadonlySet<B>

Defined in: Data/Uniq.ts:163

Applies f to each item, returning a new collection of the results. Duplicate results are automatically merged.

A

B

(a) => B

(s) => ReadonlySet<B>

pipe(Uniq.fromArray([1, 2, 3, 4]), Uniq.map(n => n % 3)); // ReadonlySet { 1, 2, 0 }