Describe the bug.
Both Feedback.tsx and NewsletterSubscribe.tsx use fetch() without a .catch() block or try/catch wrapper. This causes unhandled promise rejections, and any network failure results in the UI not updating properly or potentially crashing.
Expected behavior
Fetch requests should gracefully handle network errors and update the component state accordingly (e.g., show error UI). The app should never crash due to missing error handling.
Screenshots
.
How to Reproduce
- Open the page with the Feedback or Newsletter Subscribe form.
- Turn off your internet or simulate offline mode.
- Submit the form.
- Notice nothing happens and no error is shown.
🖥️ Device Information [optional]
- Operating System (OS):
- Browser:
- Browser Version:
👀 Have you checked for similar open issues?
🏢 Have you read the Contributing Guidelines?
Are you willing to work on this issue ?
Yes I am willing to submit a PR!