Blockbench Reference Docs
    Preparing search index...

    Function Condition

    • Tests if a condition is truthy of falsy. Returns true if the condition is unspecified

      Parameters

      • condition: any

        Boolean, function, any or anything else

      Returns boolean

    • Parameters

      • condition: boolean | (() => boolean)

        Input condition. Can be undefined, a boolean, a function or a condition any

      • context: any

        Reusable data types that can be used by anything, but should not be used to store data between function calls. Can be used to save memory on frequent function calls.

      Returns boolean