how do i filter an array from the given values of another array? The newCampaignId varable is the one i want to filter through. I do it like so:
const newCampaignId = ["101","102","103","104"] // not used
const newCampaign = subscriptions.filter((sub) => sub.id == "101" || sub.id == "102" || sub.id =="103" || sub.id == "104");
But i am sure there is an easier way of doing this. Any ideas?