@metreeca/core - v0.9.22
    Preparing search index...

    Function one

    • Requires exactly one validator to pass.

      Rejects ambiguity as well as absence: matching no validator is unsatisfiable, matching several is ambiguous, and both are reported as a bare message telling the two apart.

      Type Parameters

      • T

        The type of the validated value

      Parameters

      • ...validators: readonly Modal<Validator<T>>[]

        The mutually exclusive validators; omitted or disabled validators are ignored

      Returns Validator<T>

      A validator reporting a violation unless exactly one enabled validator passes