Skip to main content Link Search Menu Expand Document (external link)

Identity overview

Added in v1.0.0


Table of contents


do notation

Do

Signature

export declare const Do: {}

Added in v1.0.0

andThenBind

A variant of bind that sequentially ignores the scope.

Signature

export declare const andThenBind: {
  <N extends string, A extends object, B>(name: Exclude<N, keyof A>, that: B): (self: A) => {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
  <A extends object, N extends string, B>(self: A, name: Exclude<N, keyof A>, that: B): {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
}

Added in v1.0.0

bind

Signature

export declare const bind: {
  <N extends string, A extends object, B>(name: Exclude<N, keyof A>, f: (a: A) => B): (self: A) => {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
  <A extends object, N extends string, B>(self: A, name: Exclude<N, keyof A>, f: (a: A) => B): {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
}

Added in v1.0.0

bindTo

Signature

export declare const bindTo: {
  <N extends string>(name: N): <A>(self: A) => { [K in N]: A }
  <A, N extends string>(self: A, name: N): { [K in N]: A }
}

Added in v1.0.0

let

Signature

export declare const let: {
  <N extends string, A extends object, B>(name: Exclude<N, keyof A>, f: (a: A) => B): (self: A) => {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
  <A extends object, N extends string, B>(self: A, name: Exclude<N, keyof A>, f: (a: A) => B): {
    [K in N | keyof A]: K extends keyof A ? A[K] : B
  }
}

Added in v1.0.0

instances

Applicative

Signature

export declare const Applicative: applicative.Applicative<IdentityTypeLambda>

Added in v1.0.0

Chainable

Signature

export declare const Chainable: chainable.Chainable<IdentityTypeLambda>

Added in v1.0.0

Covariant

Signature

export declare const Covariant: covariant.Covariant<IdentityTypeLambda>

Added in v1.0.0

FlatMap

Signature

export declare const FlatMap: flatMap_.FlatMap<IdentityTypeLambda>

Added in v1.0.0

Foldable

Signature

export declare const Foldable: foldable.Foldable<IdentityTypeLambda>

Added in v1.0.0

Invariant

Signature

export declare const Invariant: invariant.Invariant<IdentityTypeLambda>

Added in v1.0.0

Monad

Signature

export declare const Monad: monad.Monad<IdentityTypeLambda>

Added in v1.0.0

Of

Signature

export declare const Of: of_.Of<IdentityTypeLambda>

Added in v1.0.0

Pointed

Signature

export declare const Pointed: pointed.Pointed<IdentityTypeLambda>

Added in v1.0.0

Product

Signature

export declare const Product: product_.Product<IdentityTypeLambda>

Added in v1.0.0

SemiApplicative

Signature

export declare const SemiApplicative: semiApplicative.SemiApplicative<IdentityTypeLambda>

Added in v1.0.0

SemiProduct

Signature

export declare const SemiProduct: semiProduct.SemiProduct<IdentityTypeLambda>

Added in v1.0.0

Traversable

Signature

export declare const Traversable: traversable.Traversable<IdentityTypeLambda>

Added in v1.0.0

getSemiAlternative

Signature

export declare const getSemiAlternative: <A>(
  S: Semigroup<A>
) => semiAlternative.SemiAlternative<IdentityTypeLambdaFix<A>>

Added in v1.0.0

getSemiCoproduct

Signature

export declare const getSemiCoproduct: <A>(S: Semigroup<A>) => semiCoproduct.SemiCoproduct<IdentityTypeLambdaFix<A>>

Added in v1.0.0

models

Identity (type alias)

Signature

export type Identity<A> = A

Added in v1.0.0

type lambdas

IdentityTypeLambda (interface)

Signature

export interface IdentityTypeLambda extends TypeLambda {
  readonly type: Identity<this['Target']>
}

Added in v1.0.0

IdentityTypeLambdaFix (interface)

Signature

export interface IdentityTypeLambdaFix<A> extends TypeLambda {
  readonly type: Identity<A>
}

Added in v1.0.0