Table of contents


ExchangeRate (interface)

Signature

export interface ExchangeRate<S, D> extends Newtype<['ExchangeRate', S, D], PositiveRational> {}

unwrap (constant)

Signature

export const unwrap: <S, D>(er: ExchangeRate<S, D>) => PositiveRational = ...

wrap (constant)

Signature

export const wrap: <S, D>(r: PositiveRational) => ExchangeRate<S, D> = ...

compose (function)

Signature

export function compose<A, B, C>(bc: ExchangeRate<B, C>, ab: ExchangeRate<A, B>): ExchangeRate<A, C> { ... }

exchange (function)

Signature

export const exchange = <S extends string, D extends string>(er: ExchangeRate<S, D>) => (d: Dense<S>): Dense<D> => ...

getOrd (function)

Signature

export const getOrd = <S, D>(): Ord<ExchangeRate<S, D>> => ...

getSetoid (function)

Signature

export const getSetoid = <S, D>(): Setoid<ExchangeRate<S, D>> => ...