[英]How to send custom state which has url or pathname from front end to backend for redirecting the page to current url after login in react with azuread
landing page need to be same as requested url after logging in .登陆页面需要与登录后请求的url相同。 So thought of using custom state in which url or pathname should be stored .
所以想到使用自定义状态,其中应该存储 url 或 pathname 。 So how should i access the previous url , if i need to get it from frontend how can I get it without using props.history.push ?
那么我应该如何访问以前的 url,如果我需要从前端获取它,我如何在不使用 props.history.push 的情况下获取它? Please suggest some ideas
请提出一些想法
Please check if this can narrow down the issue:请检查这是否可以缩小问题的范围:
navigateToLoginRequestUrl
is set to true
in userAgentApplication callback constructor.navigateToLoginRequestUrl
设置为true
。 By default, msal tries to take you back to the loginStartPage after successful authentication.References:参考:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.