Inherit from AuthenticationStateProvider or CslaAuthenticationStateProvide #4016
-
Hello Everyone If the answer is CslaAuthenticationStateProvider, what are the benefits? Thanks in advance |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 14 replies
-
Is this on the server or wasm? I assume wasm, because we removed any custom authn stuff from On the wasm client, there is (or was) no default AuthenticationStateProvider provided generically, and so CSLA includes one with a very simple implementation - just so people can have a simple place to store the user identity. It doesn't do anything special, and all CSLA needs is that there actually be an authn state provider that maintains the user principal. CSLA uses a try pattern to add the In summary, I'd recommend subclassing |
Beta Was this translation helpful? Give feedback.
-
Hi @ecaldentey and @rockfordlhotka I've used the
I can't figure out why it works in the ProjectTracker example. If I inject a |
Beta Was this translation helpful? Give feedback.
This is a known issue: dotnet/aspnetcore#53996
Using an extension method
HttpContext.RedirectTo(...)
, with[CascadingParameter] public HttpContext? HttpContext { get; set; }
and addingmethod="post" Enhance
to theEditForm
is a workaround.