-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Description
Is there an existing issue for this?
- I have searched the existing issues
Is your feature request related to a problem? Please describe the problem.
I tried to use the AuthorizationPolicy.Combine function combining two or more policies to a new policy, then assigning to the AuthorizeView. I found that Blazor's AuthorizeView component does not support the AuthorizationPolicy.Combine function result. I hope it can work in the future. It can be used in more situations when the policies are complex or have complex condition situations.
Describe the solution you'd like
I want to solve the AuthorizeView, which has complex policies and roles, but every policy is independent. The role part is also independent. Some situations will be an A + B policy, so I must create a new policy for these combined results and then assign it to the AuthorizeView component. Let it approach the clean code and be easy to read.
My solution is to use the AutorizeView component nested policy. This policy graph is like the tree graph. When the user action navigates to another page, the authorization handler event will check the user permission data info. This solution has no benefit viewpoint. When the page nest is much bigger, the authorization handler event will delay the page render event and dom event happening time.
Additional context
No response