Currently I am using Angular 2.0. I have an array as follows:
var channelArray: Array = [\'one\', \'two\', \'three\'];
How ca
Use JavaScript Array includes() Method
var fruits = ["Banana", "Orange", "Apple", "Mango"];
var n = fruits.includes("Mango");
Try it Yourself » link
Definition
The includes() method determines whether an array contains a specified element.
This method returns true if the array contains the element, and false if not.