Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/xotic750/is-nil-x

Checks if `value` is `null` or `undefined`.
https://github.com/xotic750/is-nil-x

browser ecmascript nodejs null test undefined

Last synced: 2 months ago
JSON representation

Checks if `value` is `null` or `undefined`.

Awesome Lists containing this project

README

        


Travis status


Dependency status


devDependency status


npm version


jsDelivr hits


bettercodehub score


Coverage Status

## is-nil-x

Checks if `value` is `null` or `undefined`.

### `module.exports(value)` ⇒ boolean

Checks if `value` is `null` or `undefined`.

**Kind**: Exported function
**Returns**: boolean - Returns `true` if `value` is nullish, else `false`.

| Param | Type | Description |
| ----- | --------------- | ------------------- |
| value | \* | The value to check. |

**Example**

```js
import isNil from 'is-nil-x';

console.log(isNil(null)); // => true
console.log(isNil(void 0)); // => true
console.log(isNil(NaN)); // => false
```