import { isObject } from "./isObject" ; returns { boolean } export function isPlainObject ( arg ) { if ( ! isObject ( arg ) ) return false ; const proto = Object . getPrototypeOf ( arg ) ; if ( proto == null ) return true ; return proto . constructor ?. toString ( ) === Object . toString ( ) ; }