UNPKG

@n3okill/utils

Version:
19 lines 696 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isPlainObject = isPlainObject; const isFunction_1 = require("./isFunction"); const isObject_1 = require("./isObject"); /** * Check if argument is a plain object * @param arg * @returns {boolean} */ // eslint-disable-next-line @typescript-eslint/no-explicit-any function isPlainObject(arg) { return (!!arg && (0, isObject_1.isObject)(arg) && (0, isFunction_1.isFunction)(arg.constructor) && (0, isObject_1.isObject)(arg.constructor.prototype) && Object.prototype.hasOwnProperty.call(arg.constructor.prototype, "isPrototypeOf")); } //# sourceMappingURL=isPlainObject.js.map