Svelte · Senior · Question 73 of 75
Why do SvelteKit form actions return 303 redirects or fail instead of rendering errors directly?
- ✓Correct answer: POST-redirect-GET avoids duplicate submissions on reload, and
failkeeps the user on the page with validation data and a proper 4xx status - 2Browsers can't render responses to POST
- 3It's required by HTTP/2
Explanation
With use:enhance the redirect is followed client-side and the UI updates without a full reload.