@kayahr/assert
    Preparing search index...

    Function assertTruthy

    • Asserts that given value is truthy.

      Type Parameters

      • T

      Parameters

      • actual: T

        The value to check.

      • Optionalreason: string

        Optional reason added to exception message when assertion fails.

      Returns asserts actual is Exclude<T, undefined | null | false | "" | 0 | 0n>

      AssertionError when value is not truthy.