I have some code that redirects the user to a confirmation page after is sent successfully.
There, I use the following code:
I use a hash in the action url of my form:
<form novalidate action="/en/<current-page>#newsletter-footer" method="POST">
This ensures, the page scrolls to the form in case it was marked as invalid by the server.
Now the issue is, the redirect with
go() still includes the hash. Which makes it directly scroll to the form in the footer on the confirmation page.
How do I make a “clean” redirect without the hash being applied? Do I need to use
visit() or any other function?