aboutsummaryrefslogtreecommitdiff
path: root/node_modules/is-plain-obj/readme.md
blob: 269e56aeff0646e8f5422a577054cb2796ed400c (plain)
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
# is-plain-obj [![Build Status](https://travis-ci.org/sindresorhus/is-plain-obj.svg?branch=master)](https://travis-ci.org/sindresorhus/is-plain-obj)

> Check if a value is a plain object

An object is plain if it's created by either `{}`, `new Object()` or `Object.create(null)`.


## Install

```
$ npm install --save is-plain-obj
```


## Usage

```js
var isPlainObj = require('is-plain-obj');

isPlainObj({foo: 'bar'});
//=> true

isPlainObj([1, 2, 3]);
//=> false
```


## Related

- [is-obj](https://github.com/sindresorhus/is-obj) - Check if a value is an object


## License

MIT © [Sindre Sorhus](http://sindresorhus.com)