Currently I am using Angular 2.0. I have an array as follows:
var channelArray: Array = [\'one\', \'two\', \'three\'];
How ca
You can use the some method:
console.log(channelArray.some(x => x === "three")); // true
You can use the find method:
console.log(channelArray.find(x => x === "three")); // three
Or you can use the indexOf method:
console.log(channelArray.indexOf("three")); // 2