a-plain-obj
TypeScript icon, indicating that this package has built-in type declarations

1.5.5 • Public • Published

Is it a plain object? ~100B

NPM Version NPM Version NPM package ( download / month ) Follow @mastercorg Github release actions


Getting Started

npm install a-plain-obj

Usage

import aPlainObj from 'a-plain-obj'

aPlainObj({})
// true

Overview

// true
aPlainObj(Object.create({}))
aPlainObj(Object.create(Object.prototype))
aPlainObj({ foo: 'bar' })
aPlainObj({})
aPlainObj(Object.create(null))

// false
function Foo() { this.abc = {} }
aPlainObj(/foo/)
aPlainObj(function () { })
aPlainObj(1)
aPlainObj(['foo', 'bar'])
aPlainObj([])
aPlainObj(new Foo)
aPlainObj(null)
aPlainObj(undefined)

NPM Version

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i a-plain-obj

      Homepage

      aron.tw

      Weekly Downloads

      1

      Version

      1.5.5

      License

      MIT

      Unpacked Size

      6.13 kB

      Total Files

      5

      Last publish

      Collaborators

      • 1aron