Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

getComparableSet

import { getComparableSet } from "https://github.gh-proxy.cn/raw.githubusercontent.com/baetheus/fun/main/set.ts";

Given an instance of Comparable return Comparable<ReadonlySet>.

@example
import * as S from "./set.ts";
import * as N from "./number.ts";
import { pipe } from "./fn.ts";

const { compare } = S.getComparableSet(N.ComparableNumber);

const result1 = compare(
  S.set(1, 2, 3))(
  S.set(3, 2, 1)
); // true
const result2 = compare(
  S.set(1, 2, 3))(
  S.set(1, 2, 3, 4)
); // false
function getComparableSet<A>(S: Comparable<A>): Comparable<ReadonlySet<A>>;
§
getComparableSet<A>(S: Comparable<A>): Comparable<ReadonlySet<A>>
[src]

§Type Parameters

§Parameters

§Return Type

§
Comparable<ReadonlySet<A>>
[src]