* @ngdoc function * @name angular.fromJson * @module ng * @kind function * * @description * Deserializes a JSON string. * * @param {string} json JSON string to deserialize. * @returns {Object|Array|string|number} Deserialized thingy.
(json)
| 1130 | * @returns {Object|Array|string|number} Deserialized thingy. |
| 1131 | */ |
| 1132 | function fromJson(json) { |
| 1133 | return isString(json) |
| 1134 | ? JSON.parse(json) |
| 1135 | : json; |
| 1136 | } |
| 1137 | |
| 1138 | |
| 1139 | function toBoolean(value) { |
no test coverage detected