UNPKG

vanilla-type-check

Version:
16 lines (15 loc) 428 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * Check if a value is an object * * @param value value to check * @returns `true` if `obj` is an object */ function isObject(value) { var type = typeof value; return value != null && (type === 'object' || type === 'function') && toString.call(value) !== '[object Array]'; } exports.isObject = isObject;