You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Put emit("replaceState", "/") inside a route and be sad that you don't get redirected.
I'm using fastify for the server so I'll try intercepting choo to make redirects happen via fastify instead. I'd rather do it programmatically in choo though.
The text was updated successfully, but these errors were encountered:
// relevant portionif(!fs.existsSync(`./documents/${path}.md`))returnredirect404(state,emit);// when I add emit here, it does get passed to my redirect-404.js file
// ...but replacing the HTML in that file with the code below results in nothingsetTimeout(()=>{emit("replaceState",redirectUrl);},0);
Expected behavior
emit("replaceState", "/")
redirects a user to the specified URL.Actual behavior
Nothing happens. Even the official site has this issue.
Steps to reproduce behavior
Put
emit("replaceState", "/")
inside a route and be sad that you don't get redirected.I'm using fastify for the server so I'll try intercepting choo to make redirects happen via fastify instead. I'd rather do it programmatically in choo though.
The text was updated successfully, but these errors were encountered: