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
Since apiActions created via createRequest are typically handled in the reducer (via handleSuccess, handleFailure, or handleResponse), we usually do not add .catch() statements to each individual call that is mapped to dispatch as a prop. This results in some confusing console error message when a call fails (see LaunchPadLab/lp-requests#87).
Given that the default behavior is to not handle this error, I'm wondering if we should include an option that either:
Returns the error (but doesn't throw it); or
Ignores the error (after calling failureAction and onUnauthorized)
An option could be failSilently or ignoreError? Need to do a bit of research about best practices / conventions.
The text was updated successfully, but these errors were encountered:
Since apiActions created via
createRequest
are typically handled in thereducer
(viahandleSuccess
,handleFailure
, orhandleResponse
), we usually do not add.catch()
statements to each individual call that is mapped to dispatch as a prop. This results in some confusing console error message when a call fails (see LaunchPadLab/lp-requests#87).Given that the default behavior is to not handle this error, I'm wondering if we should include an option that either:
failureAction
andonUnauthorized
)An option could be
failSilently
orignoreError
? Need to do a bit of research about best practices / conventions.The text was updated successfully, but these errors were encountered: