If you would like to check the implementation of how to filter and sort an array of nested objects only, you can check the below story: Searching through an array of objects and arrays is very… 23.4k 27 27 gold badges 96 96 silver badges 139 139 bronze badges. How to calculate the number of days between two dates in javascript? share | improve this question | follow | asked Jul 10 '13 at 18:55. wesbos wesbos. download the GitHub extension for Visual Studio. That means it won't return intermediate keys. Working with nested objects is frequent in JavaScript ; so I made this screen cast around this question. Writing code in comment? As described earlier, each nested object is indexed as a separate Lucene document. Export the Underscore object for Node.js, with backwards-compatibility for their old module API. close, link This wrapper holds altered versions of all functions added through _.mixin. var result = A2.filter(o => A1.includes(o.value)); If you wanted to use Underscore.js, _.filter() and _.includes() could be used to filter out any object in A2 without a value for the value property contained in A1. We learned before that nesting resources could make our URLs more readable, but this isn’t a sure bet. How to set the default value for an HTML