I have a key value pair which is dynamic.
myObj = {
category1: ["a","b","c"],
category2: ["a","d","e"],
category3: ["a","f","g"],
...
..
.
}
I need to get intersection value as "a". For that I'm using underscore js's
_.intersection() function
Depending on dynamic categories, I need to pass dynamic arguments to _.intersection()
like
_.intersection(myObj[category1], myObj[category2], ..., ..., myObj[categoryN]);