static-web-apps-cli
static-web-apps-cli copied to clipboard
Debug the roles function using the local auth emulator
Is your feature request related to a problem? Please describe. Enable local dev for role management through serverless functions
Describe the solution you'd like Test programmatically assigned roles in local environment
Describe alternatives you've considered Call the auth function locally with something like Postman to ensure it responds with the right roles given an input. Use the local emulator to set custom roles at login to test how your app works with different roles.
Additional context Tutorial: Assign custom roles with a function and Microsoft Graph
Related to #306
I will look at this post-GA.
The current workaround is to print a warning if we detect the auth in the staticwebapp.config.json
What is the current status of this? I was attempting to enable role management and test locally. I expected my GetRoles function to be called but it wasn't after login. I was able to call GetRoles directly. I was hoping not to debug in a live SWA deployment.
I'm using SWA CLI ver 1.01 and C#(.net6).
Hi @c0g1t8, We have this in our radar and will be working on this shortly. We do not have a timeline yet to commit this, but you should be seeing some update in a couple of months.
cc// @sgollapudi77