Constructor
# new IsArray()
- Since:
- 1.3.0
- Copyright:
- schukai GmbH
Example
import {IsArray} from 'https://cdn.jsdelivr.net/npm/@schukai/monster@1.23.0/dist/modules/constraints/isarray.js';
new IsArray()
.isValid([])
.then(()=>console.log(true));
// ↦ true
new IsArray()
.isValid(99)
.catch(e=>console.log(e));
// ↦ 99
Methods
# isValid(value) → {Promise}
this method return a promise containing the result of the check.
Parameters:
Name | Type | Description |
---|---|---|
value |
* |
Returns:
- Type
- Promise