Wednesday, 10 May 2017

Convert name value to JSON object

I would like to convert below array of name-value pair to JSON object.

Input

Data = [ {"name":"aaa", "value":111},{"name":"bbb", "value":222}]

Expected output

Data = {"aaa":111, "bbb":222}



via Muzaffer

No comments:

Post a Comment