How to parse JSON string in JavaScript

JSON
By Jad Joubran · 
Last updated Jan 11, 2018
const string = '{"id":1,"name":"Leanne Graham"}';

JSON.parse(string);
{
    id: 1,
    name: "Leanne Graham"
}
JSON.parse on MDN