You cannot select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
	
	
		
			42 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			JavaScript
		
	
		
		
			
		
	
	
			42 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			JavaScript
		
	
| 
											9 months ago
										 | "use strict"; | ||
|  | Object.defineProperty(exports, "__esModule", { | ||
|  |     value: true | ||
|  | }); | ||
|  | 0 && (module.exports = { | ||
|  |     getObjectClassLabel: null, | ||
|  |     isPlainObject: null | ||
|  | }); | ||
|  | function _export(target, all) { | ||
|  |     for(var name in all)Object.defineProperty(target, name, { | ||
|  |         enumerable: true, | ||
|  |         get: all[name] | ||
|  |     }); | ||
|  | } | ||
|  | _export(exports, { | ||
|  |     getObjectClassLabel: function() { | ||
|  |         return getObjectClassLabel; | ||
|  |     }, | ||
|  |     isPlainObject: function() { | ||
|  |         return isPlainObject; | ||
|  |     } | ||
|  | }); | ||
|  | function getObjectClassLabel(value) { | ||
|  |     return Object.prototype.toString.call(value); | ||
|  | } | ||
|  | function isPlainObject(value) { | ||
|  |     if (getObjectClassLabel(value) !== "[object Object]") { | ||
|  |         return false; | ||
|  |     } | ||
|  |     const prototype = Object.getPrototypeOf(value); | ||
|  |     /** | ||
|  |    * this used to be previously: | ||
|  |    * | ||
|  |    * `return prototype === null || prototype === Object.prototype` | ||
|  |    * | ||
|  |    * but Edge Runtime expose Object from vm, being that kind of type-checking wrongly fail. | ||
|  |    * | ||
|  |    * It was changed to the current implementation since it's resilient to serialization. | ||
|  |    */ return prototype === null || prototype.hasOwnProperty("isPrototypeOf"); | ||
|  | } | ||
|  | 
 | ||
|  | //# sourceMappingURL=is-plain-object.js.map
 |