Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error handling middleware #182

Open
mstone121 opened this issue Nov 7, 2022 · 0 comments
Open

Error handling middleware #182

mstone121 opened this issue Nov 7, 2022 · 0 comments
Labels
polish Ideas for improvement by Azavea Task 3.6 Front-end implementation

Comments

@mstone121
Copy link
Contributor

Overview

Add a redux store middleware to handle API errors

Is your feature request related to a problem? Please describe.

We're using useEndpointToastError everywhere we're using a mutation hook. This feels redundant.

Describe the solution you'd like

Move the functionality from useEndpointToastError into a redux store middleware.

Additional Context

https://redux-toolkit.js.org/rtk-query/usage/error-handling#handling-errors-at-a-macro-level

@rajadain rajadain added Task 3.6 Front-end implementation polish Ideas for improvement by Azavea labels Nov 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
polish Ideas for improvement by Azavea Task 3.6 Front-end implementation
Projects
None yet
Development

No branches or pull requests

2 participants