Type alias Unary<Input, Output>

Unary<Input, Output>: ((input: Input) => Output)

Type Parameters

  • Input

  • Output

Type declaration

    • (input: Input): Output
    • Unary function (takes a single value).

      Example

      const unary: Unary<number, number> = n => n + 1;
      

      Parameters

      • input: Input

      Returns Output