how should we convert string data into array and display into react table

I have imported CSV data and converted into the following stringData. Now I have to display this stringData in a React table. I have tried using map function to separate the headers and map to <th> but when I tried to display the values into <tr> it is considering each row as one value. Please let me know if there is any other way of doing this. Thanks

const stringData = "BRANCH,ITEMNUM,UNITCOST,COSTMETHOD
34,130156,86.25,51
34,220134,75.8425,51
34,190365,53.5325,51
34,200350,18.4,51"

2 thoughts on “how should we convert string data into array and display into react table”

  1. 840015 252817hello!,I genuinely like your writing extremely a good deal! percentage we keep up a correspondence extra about your article on AOL? I need to have an expert on this region to unravel my issue. Could be that is you! Taking a appear forward to peer you. 963347

    Reply

Leave a Comment