Saturday, 15 September 2012

Find a value in json object using lodash methods flatten and find -


Using the Launch I want to find a team whose ID is 3229. I tried the following, but it is not returning anything.

  var team = _.chain (data.times). Fleeton ("DivisionTime") .Fund ({"id": 3229}) .value ();  

This is my plunker code I

For Jason Data, please see the file data.js in Plunker

Please note that I can not change Jason data because I'm calling a test API.

flat does not take argument, see you either map or screaming to the division templates .

  _ chain (data.teams) is required. Burst ('division tag'). Fleeton () .find ({id: 3232}) .value ();  

No comments:

Post a Comment