Search code examples
javascriptarraysreactjsmongodbmern

MERN-How to get data which is in array


I have an react-app .. I don't know the method to get data from the array from mongo db which has a structure image

I used {this.props.obj.index} to get index value and so on.. but i dont know how to gegt from array {this.props.obj.songdata.object.songindex} . help me


Solution

  • use {this.props.obj.songdata[0].songindex}