pdf-lite - v1.0.1
    Preparing search index...

    Function assert

    • Asserts that a value is truthy, throwing an error if it is not.

      Parameters

      • value: unknown

        The value to check.

      • Optionalmessage: string

        Optional error message to throw if the assertion fails.

      Returns asserts value

      Error if the value is falsy.

      assert(user !== null, 'User must be defined')