You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thrownewError(`Bad response for ${this.displayUrl} (${response.status}): ${response.statusText}`)
Could that line be changed to the following?
thrownewError(`Bad response for ${this.displayUrl} (${response.status}): ${response.statusText}`,{cause: response})
That would then provide the whole failed response object for further processing. It would help write much more defensive code when 429's, 401's, etc. are found while collecting data.
Thanks!
🎩
The text was updated successfully, but these errors were encountered:
First, thank you for building eleventy-fetch! It has been great for the GET + cache pattern that's so common in static site building.
However, dealing with error responses continues to be painful since eleventy-fetch only returns a prose message:
eleventy-fetch/src/RemoteAssetCache.js
Line 73 in 28201ee
Could that line be changed to the following?
That would then provide the whole failed response object for further processing. It would help write much more defensive code when 429's, 401's, etc. are found while collecting data.
Thanks!
🎩
The text was updated successfully, but these errors were encountered: