fix: redirect when using RSC
This PR fixes redirects when using RSC rendering, including redirecting when using navigation with <Link> component from @lazarv/react-server/navigation.
As redirects are throwing a redirect error, this means that this PR implements enhanced error handling for RSC payloads, handling the request gracefully when an error is included in the RSC payload. In case there's a client-side error during the RSC request, a new RSC payload is constructed with the error included.
The redirect() function is now aware of what type of response is expected using the rendering context and sets an RSC payload as the redirect response for RSC requests.
The file-system based router was fixed to handle middleware redirects when using a web standard Response.redirect response with an RSC context. When detected, the response will be changed to an RSC redirect error.
Client-side redirect handling is now aware about external redirects and in case of the redirect location is external, it fires a browser page navigation using replace.
Error boundary components are now handling browser history change with a page reload when needed, to re-render the page after navigation.
The file-router example app was extended to include various redirect use cases, and the test suite for the example app was also extended to test redirects too.