File: .verb.md

package info (click to toggle)
node-isobject 3.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 120 kB
  • sloc: sh: 5; makefile: 4
file content (38 lines) | stat: -rw-r--r-- 696 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
Use [is-plain-object](https://github.com/jonschlinkert/is-plain-object) if you want only objects that are created by the `Object` constructor.

## Install
{%= include("install-npm", {save: 'save'}) %}
{%= include("install-bower", {save: 'save'}) %}

## Usage

```js
var isObject = require('{%= name %}');
```

**True**

All of the following return `true`:

```js
isObject({});
isObject(Object.create({}));
isObject(Object.create(Object.prototype));
isObject(Object.create(null));
isObject({});
isObject(new Foo);
isObject(/foo/);
```

**False**

All of the following return `false`:

```js
isObject();
isObject(function () {});
isObject(1);
isObject([]);
isObject(undefined);
isObject(null);
```