collect.js
Advanced tools
Comparing version 4.0.3 to 4.0.4
@@ -153,5 +153,5 @@ type Operator = "===" | "==" | "!==" | "!=" | "<>" | ">" | "<" | ">=" | "<=" | ||
/** | ||
* The has method determines if a given key exists in the collection. | ||
* The has method determines if one or more keys exists in the collection. | ||
*/ | ||
has<K>(key: K): boolean; | ||
has<K>(key: K | Item[]): boolean; | ||
@@ -158,0 +158,0 @@ /** |
{ | ||
"name": "collect.js", | ||
"version": "4.0.3", | ||
"version": "4.0.4", | ||
"description": "Convenient and dependency free wrapper for working with arrays and objects.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -758,3 +758,3 @@ # <img src="https://raw.githubusercontent.com/ecrmnn/collect.js/master/collectjs.jpg" alt="collect.js"> | ||
#### ``has()`` | ||
The has method determines if a given key exists in the collection: | ||
The has method determines if one or more keys exists in the collection: | ||
```js | ||
@@ -769,2 +769,10 @@ const collection = collect({ | ||
//=> true | ||
collection.has(['animal', 'ability']); | ||
//=> true | ||
collection.has(['animal', 'ability', 'name']); | ||
//=> false | ||
``` | ||
@@ -771,0 +779,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
363578
2077