-
Hi, I would like to ask for help. Is it possible to send http status (for example 403) from hono middleware to react router and render custom 403 page from react router? Thanks, |
Beta Was this translation helpful? Give feedback.
Answered by
rphlmr
Jan 9, 2025
Replies: 1 comment 2 replies
-
I should test to be sure but I would try a middleware, before every other middleware. It would await next() and then check if the c.res.status is 403 and then redirect to /403. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
jezikk
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I should test to be sure but I would try a middleware, before every other middleware.
It would await next() and then check if the c.res.status is 403 and then redirect to /403.
It will then re enter and hit the rr middleware.