forked from orbit-oss/is
parent
c3d12667fd
commit
04ccf21dba
1 changed files with 10 additions and 2 deletions
12
readme.md
12
readme.md
|
|
@ -17,8 +17,8 @@ For example, `is.string('🦄') //=> true`
|
|||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install @sindresorhus/is
|
||||
```sh
|
||||
npm install @sindresorhus/is
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
|
@ -82,6 +82,9 @@ All the below methods accept a value and returns a boolean for whether the value
|
|||
|
||||
##### .undefined(value)
|
||||
##### .null(value)
|
||||
|
||||
**Note:** TypeScript users must use `.null_()` because of a TypeScript naming limitation.
|
||||
|
||||
##### .string(value)
|
||||
##### .number(value)
|
||||
|
||||
|
|
@ -103,6 +106,9 @@ is.array(value, is.number); // Validate `value` is an array and all of its items
|
|||
```
|
||||
|
||||
##### .function(value)
|
||||
|
||||
**Note:** TypeScript users must use `.function_()` because of a TypeScript naming limitation.
|
||||
|
||||
##### .buffer(value)
|
||||
##### .object(value)
|
||||
|
||||
|
|
@ -372,6 +378,8 @@ An object is plain if it's created by either `{}`, `new Object()`, or `Object.cr
|
|||
|
||||
Returns `true` for instances created by a class.
|
||||
|
||||
**Note:** TypeScript users must use `.class_()` because of a TypeScript naming limitation.
|
||||
|
||||
##### .typedArray(value)
|
||||
|
||||
##### .arrayLike(value)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue