[英]IdentityServer4 - Angular how to change the default Login page to Angular component
How can I change the Login.cs.html page from IdentityServer4 to Angular component?如何将 Login.cs.html 页面从 IdentityServer4 更改为 Angular 组件?
What should I do exactly?我该怎么做?
Thanks谢谢
You can set the path to the login page via the UserInteraction settings .您可以通过UserInteraction 设置设置登录页面的路径。 Read more about IDS4 login flow here .
在此处阅读有关 IDS4 登录流程的更多信息。
For example if you have the angular app hosted on http://localhost:3000
settings looks like this:例如,如果您在
http://localhost:3000
上托管了 angular 应用程序,则设置如下所示:
services.AddIdentityServer(
options =>
{
options.UserInteraction.LoginUrl = "http://localhost:3000/login";
options.UserInteraction.ErrorUrl = "http://localhost:3000/error";
options.UserInteraction.LogoutUrl = "http://localhost:3000/logout";
})
.AddInMemoryIdentityResources(Config.GetIdentityResources())
.AddInMemoryApiResources(Config.GetApis())
.AddInMemoryClients(Config.GetClients())
.AddTestUsers(Config.GetTestUsers());
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.