I have an array of objects that I get from an ajax call, each object has properties like in this example:
Name: Bob Dylan
Value: 452342
I also have an inclusion array of values, that if not empty I need to filter the array of objects above to contain only the ones with values from the inclusion array.
Update: Example of inclusion array is simply: [452342, 4563546,34563,34563456,345634]
My best guess was to have 2 loops, outer one going through the array of objects and inner one checking if they exist in the inclusion list, and if not slicing that object. Is there a better, less laborious way of doing this?