@aws-quickstart/eks-blueprints
    Preparing search index...

    Function validateConstraints

    • This function validates the given object by the given constraints, and returns an error that uses the given context if needed.

      Type Parameters

      • T

      Parameters

      • constraints: Partial<Record<keyof T, Constraint>>

        This is the keys of the object with specified values for validation.

      • context: string

        Object type name for error context purposes.

      • ...object: any

        The given object type, an array of or only a single object, to be validated.

      Returns void

      throws a Zod Error if validations are broken.