I am using angular's fromJson function to parse a json string. If the json is a simple array, like "[1, 2]", then the following code is working. But what I need is an array of dictionaries.
var str = "[{'title':'hi'}, {'title':'what'}]"
alert(str) //1
alert(str.length) //2
var j = angular.fromJson(str)
alert(j) //3
alert(j.length) //4
1 and 2 are alerted out, which are string representation 3 and 4 are not, which means fromJson has error.
Note: It has nothing to do with JSON.parse or $._parseJSON functions. I need to use the angular one for some reasons.