Open Sahanaa opened 7 years ago
This typescript error occurs while integrating with Yahoo API. I think this doesn't work with angularjs ^1.4.0.
Check the code below -
`$http.jsonp(url + '&callback=JSON_CALLBACK') .success(function (data) { if (data.query.count) { var quotes = data.query.count > 1 ? data.query.results.quote : [data.query.results.quote]; update(quotes); } }) .error(function (data) { console.log("error"); console.log(data); });`
in angularjs 1.6+ jsonp() no longer supports .success() and .error() methods, but instead single method .then(successCallback, errorCallback) (or like this: .then(function(response){...}, function(response){...}); )
This typescript error occurs while integrating with Yahoo API. I think this doesn't work with angularjs ^1.4.0.
Check the code below -