Socket
Socket
Sign inDemoInstall

objectorarray

Package Overview
Dependencies
0
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    objectorarray

Is the value an object or an array but not null?


Version published
Weekly downloads
3.1M
decreased by-1.6%
Maintainers
1
Install size
3.98 kB
Created
Weekly downloads
 

Readme

Source

objectorarray

npm version downloads

Is the value an object or an array but not null or RegExp?

Install

  $ yarn add objectorarray

Usage

 import objectorarray from 'objectorarray'

True

All of the following return true:

  objectorarray({})
  objectorarray([])  
  objectorarray(Object.create({}))
  objectorarray(Object.create(Object.prototype))
  objectorarray(Object.create(null))
  objectorarray(new Foo)

False

All of the following return false:

  objectorarray()
  objectorarray(function () {})
  objectorarray(1)
  objectorarray(/foo/)
  objectorarray(undefined)
  objectorarray(null)

License

MIT

Keywords

FAQs

Last updated on 21 Jun 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc