Closed 24thsaint closed 6 years ago
I'm using fetchJsonp like so to access data on a resource which I have no control of...
fetchJsonp(url, { method: 'GET', mode: 'no-cors', credentials: 'include', }) .then(function (data) { return data.json(); }) .then(function (response) { $scope[dateTime] = new Date(response.timestamp * 1000).toLocaleString(); // ... more code
However, due to fetchJsonp adding a callback query string on the request URL, my request fails:
Error: JSONP request to https://resource.com/api/param1/param1 timed out at fetch-jsonp.js:85
Actual network request:
https://resource.com/api/param1/param1?callback=jsonp_1514919479266_12080
Is there a way for me to remove the callback on the request url due to this case?
My bad, their server does not support jsonp.
https://github.com/camsong/fetch-jsonp/issues/32#issuecomment-309177577
I'm using fetchJsonp like so to access data on a resource which I have no control of...
However, due to fetchJsonp adding a callback query string on the request URL, my request fails:
Actual network request:
Is there a way for me to remove the callback on the request url due to this case?