Don't import util
We don't really need its full power. Not worth the bloat.
This commit is contained in:
parent
6e07df5896
commit
45c976071a
4 changed files with 6 additions and 7 deletions
|
|
@ -184,7 +184,7 @@ Returns `true` if the value is an `Array` and the `.length` is more than 0.
|
|||
|
||||
##### .emptyObject(value)
|
||||
|
||||
Returns `true` if the value is an `Object` and `Object.keys(value).length` is 0.
|
||||
Returns `true` if the value is an `Object` and `Object.keys(value).length` is 0.
|
||||
|
||||
Please note that `Object.keys` returns only own enumerable properties. Hence something like this can happen:
|
||||
|
||||
|
|
@ -202,7 +202,7 @@ is.emptyObject(object1);
|
|||
// => true
|
||||
```
|
||||
|
||||
##### .nonEmptyObject(value)
|
||||
##### .nonEmptyObject(value)
|
||||
|
||||
Returns `true` if the value is an `Object` and `Object.keys(value).length` is more than 0.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue