If I have the following two objects (Object A and Object B), how can I check if Object B's key/value exists with Object A? In the below example it should return True because both 'make: "Apple"' and 'Model: "iPad"' exists in Object A.
Edit: Object B will be dynamic and may contain only Make or only Model. More keys are added dynamically via checkbox filters.
Is it easier to use a library such as Underscore? If so what functions would be applicable?
I hope this makes sense?
var a = {
Make: "Apple",
Model: "iPad",
hasScreen: "yes",
Review: "Great product!",
}
var b = {
Make: "Apple",
Model: "iPad"
}