nunof07/smalltypes

View on GitHub
src/main/function/UnaryFunction.ts

Summary

Maintainability
A
0 mins
Test Coverage
/**
 * Function with one argument.
 */
export interface UnaryFunction<X, Y> {
    /**
     * Type determinant.
     */
    isFunction(): true;

    /**
     * Apply the function to the input.
     * @param input Input.
     */
    apply(input: X): Y;
}