contains (obj) Booleandeprecatedpublic
Use Enumerable#includes instead. See http://emberjs.com/deprecations/v2.x#toc_enumerable-contains
Returns true if the passed object can be found in the receiver. The default version will iterate through the enumerable until the object is found. You may want to override this with a more efficient version.
let arr = ['a', 'b', 'c'];
arr.contains('a'); // true
arr.contains('z'); // false
Parameters:
-
obj
Object - The object to search for.
Returns:
-
Boolean - `true` if object is found in enumerable.
Please login to continue.