TIL that the fetch API won't reject a Promise if the response status is not within the success range. However, it does include an ok boolean in the response which can be used to detect server side errors.
Basically the error handling should be similar to:
TIL that the fetch API won't reject a Promise if the response status is not within the success range. However, it does include an
ok
boolean in the response which can be used to detect server side errors.Basically the error handling should be similar to:
See this blog post for more: https://www.tjvantoll.com/2015/09/13/fetch-and-errors/
This update applies to the Mailchimp API calls as well as the Geocode API calls.