Lens Scripting API

    Describes the input checker, that check if inputs are valid or not

    Index

    Constructors

    Methods

    • Throws an error if an input is undefined, otherwise, returns the input without the undefined type

      Type Parameters

      • Type

      Parameters

      • input: Type

        the input value to check, can be either typed or undefined

      • inputName: string

        the input name for logging

      Returns Type

      input with typing

    • This can be used to delay the fetching of a script property until needed, which is useful for showIf properties that may be unused.

      Type Parameters

      • T

      Parameters

      • getPropertyFunction: () => T

        The function to get the value of the property, when needed.

      • propertyName: string

        The name of the property, for logging.

      Returns () => T

      a function that will return the value of getPropertyFunction, which will only be called once

    • Log a warning if an input is undefined, otherwise, returns the input without the undefined type

      Type Parameters

      • Type

      Parameters

      • input: Type

        the input value to check, can be either typed or undefined

      • inputName: string

        the input name for logging

      Returns Type

      input with typing

    MMNEPVFCICPMFPCPTTAAATR