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: about 1 year ago
JSON representation
Checks if `value` is `null` or `undefined`.
- Host: GitHub
- URL: https://github.com/xotic750/is-nil-x
- Owner: Xotic750
- License: mit
- Created: 2015-12-11T18:49:54.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T21:54:51.000Z (over 3 years ago)
- Last Synced: 2025-04-30T20:31:56.185Z (about 1 year ago)
- Topics: browser, ecmascript, nodejs, null, test, undefined
- Language: JavaScript
- Homepage:
- Size: 3.14 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 21
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## 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
```