How to check whether string is present in array with lodash js?

Viewed 18299

My snippet looks something like this:

let go = "hello";

let col =["12","hello","14","15"];

let f = _.some(col,go);

I want to check whether the go value is present in col TRUE/FALSE. When I run this I get , f=false? How can I fix this or how to check the presence of a string in an array of strings (with lodash)?

3 Answers
Related