Checks that assertion passes for each key/value of the object.

const user = object({
name: string,
age: number,
});

user(1); // Error: type
user(null); // Error: isObject
user({
name: 1,
age: "23",
}); // Error: type
user({
name: "yamiteru",
age: 23,
}); // passes