Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "safeDecoders"

Index

Type aliases

Map

Map: function

Type declaration

    • <Decoders, T>(f: function, ...decoders: Decoders): Decoder<T>
    • Type parameters

      Parameters

      • f: function
          • (...values: object): T
          • Parameters

            • Rest ...values: object

            Returns T

      • Rest ...decoders: Decoders

      Returns Decoder<T>

Union

Union: function

Type declaration

    • <T, Values>(decoder: Decoder<T>, ...values: Values): Decoder<Values[number]>
    • Type parameters

      • T: string | number | boolean

      • Values: Array<T>

      Parameters

      • decoder: Decoder<T>
      • Rest ...values: Values

      Returns Decoder<Values[number]>

Functions

Const array

Const bool

  • bool(value: any): boolean

Const compose

  • compose(...decoders: Array<Decoder<any>>): (Anonymous function)

Const field

Const isPlainObject

  • isPlainObject(value: any): boolean

Const map

  • map(f: function, ...decoders: Array<Decoder<any>>): (Anonymous function)
  • Parameters

    • f: function
        • (...values: any): any
        • Parameters

          • Rest ...values: any

          Returns any

    • Rest ...decoders: Array<Decoder<any>>

    Returns (Anonymous function)

Const maybe

Const nil

  • nil(value: any): any

Const nullable

Const num

  • num(value: any): number

Const object

Const oneOf

  • oneOf(...decoders: Array<Decoder<any>>): (Anonymous function)

Const record

Const str

  • str(value: any): string

Const union

  • union(decoder: Decoder<any>, ...values: Array<any>): function
  • Parameters

    • decoder: Decoder<any>
    • Rest ...values: Array<any>

    Returns function

      • (value: any): T
      • Parameters

        • value: any

        Returns T