ChemPal Documentation - v0.0.13-beta.5
    Preparing search index...

    Namespace productbuilder

    Functions - Typeguards

    isAvailability

    Type guard to validate if a value is a valid availability status. Checks if the value is a string that matches one of the predefined AVAILABILITY enum values. Matching is case-insensitive — input is lowercased before comparison.

    isValidVariant

    Type guard to validate if a value is a valid product variant. Checks for the presence and correct types of variant properties. A variant can be partial as it may inherit some properties from the parent product (such as uom, currency, URL, etc.).