I am retrieving a string from Database & this string is an Array.
jq.ajax({
type: "GET",
url: "/Method/",
success: function () {
// Sample data
var data = "[{
name: "Santro",
canvas: "1"
}, {
name: "Tata",
canvas: "2"
}]";
After getting the data by AJAX call, I get the string.
How to convert this string to an Array?
JSON.parse(data);ignoring the errors