@webdeveric/utils
    Preparing search index...

    Function assertIsObject

    • Assert that input is an object.

      Parameters

      • input: unknown
      • error: string | Error = 'input is not an object'

      Returns asserts input is UnknownRecord

      assertIsObject({ a: 1 }); // does not throw
      assertIsObject(null); // throws TypeError: input is not an object
      assertIsObject([1, 2, 3]); // throws TypeError: input is not an object