Function validateWithAtLeast

  • Validate an input's fields with validators allowing extra fields

    Type Parameters

    • T

      The validated type

    Parameters

    Returns Validator<T>

    Example

    validateWithAtLeast({ a: isNumber, b: isString })({ a: 1, b: "2" }) >>
    {
    valid: true,
    input: { a: 1, b: "2" },
    };