[英]Is it possible to send a json object in a res.redirect in express?
Any way I can pass a user object in the res.redirect?我可以通过什么方式在 res.redirect 中传递用户 object?
res.redirect("/");
I added authentication later in my code and after successful signin, I am now redirecting to the home route.我稍后在我的代码中添加了身份验证,成功登录后,我现在重定向到主路由。 What do I do?
我该怎么办?
This below link may help you -以下链接可能会对您有所帮助 -
How do I redirect in expressjs while passing some context? 如何在传递一些上下文时在 expressjs 中重定向?
cheers!!干杯!!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.