HKT overview

Type defunctionalization (as describe in Lightweight higher-kinded polymorphism)

Added in v2.0.0


Table of contents


utils

HKT (interface)

* -> * constructors

Signature

export interface HKT<URI, A> {
  readonly _URI: URI
  readonly _A: A
}

Added in v2.0.0

HKT2 (interface)

* -> * -> * constructors

Signature

export interface HKT2<URI, E, A> extends HKT<URI, A> {
  readonly _E: E
}

Added in v2.0.0

HKT3 (interface)

* -> * -> * -> * constructors

Signature

export interface HKT3<URI, R, E, A> extends HKT2<URI, E, A> {
  readonly _R: R
}

Added in v2.0.0

HKT4 (interface)

* -> * -> * -> * -> * constructors

Signature

export interface HKT4<URI, S, R, E, A> extends HKT3<URI, R, E, A> {
  readonly _S: S
}

Added in v2.0.0

Kind (type alias)

* -> * constructors

Signature

export type Kind<URI extends URIS, A> = URI extends URIS ? URItoKind<A>[URI] : any

Added in v2.0.0

Kind2 (type alias)

* -> * -> * constructors

Signature

export type Kind2<URI extends URIS2, E, A> = URI extends URIS2 ? URItoKind2<E, A>[URI] : any

Added in v2.0.0

Kind3 (type alias)

* -> * -> * -> * constructors

Signature

export type Kind3<URI extends URIS3, R, E, A> = URI extends URIS3 ? URItoKind3<R, E, A>[URI] : any

Added in v2.0.0

Kind4 (type alias)

* -> * -> * -> * -> * constructors

Signature

export type Kind4<URI extends URIS4, S, R, E, A> = URI extends URIS4 ? URItoKind4<S, R, E, A>[URI] : any

Added in v2.0.0

URIS (type alias)

* -> * constructors

Signature

export type URIS = keyof URItoKind<any>

Added in v2.0.0

URIS2 (type alias)

* -> * -> * constructors

Signature

export type URIS2 = keyof URItoKind2<any, any>

Added in v2.0.0

URIS3 (type alias)

* -> * -> * -> * constructors

Signature

export type URIS3 = keyof URItoKind3<any, any, any>

Added in v2.0.0

URIS4 (type alias)

* -> * -> * -> * -> * constructors

Signature

export type URIS4 = keyof URItoKind4<any, any, any, any>

Added in v2.0.0

URItoKind (interface)

* -> * constructors

Signature

export interface URItoKind<A> {}

Added in v2.0.0

URItoKind2 (interface)

* -> * -> * constructors

Signature

export interface URItoKind2<E, A> {}

Added in v2.0.0

URItoKind3 (interface)

* -> * -> * -> * constructors

Signature

export interface URItoKind3<R, E, A> {}

Added in v2.0.0

URItoKind4 (interface)

* -> * -> * -> * -> * constructors

Signature

export interface URItoKind4<S, R, E, A> {}

Added in v2.0.0