Closed timepp closed 3 months ago
That's just how UserPrompt works, if you don't want pop-up tabs I'd recommend you to user another auth method.
You can use withAzLoginIdentity
(of course ensure you have the azure cli installed), from there you will be able to run az login
once and use the script as many times as you'd like.
Or if your user has access, you can use withTokenCredential
and pass the default TokenCredential from @azure/identity
, and have it work without any interaction.
Is your feature request related to a problem? Please describe. If I run my script 20 times, there will be 20 browser tabs created.
Describe the solution you'd like If will be great if there is an option to auto close the browser tab
Describe alternatives you've considered It's also good to have a way to save the result/token so that I can try to reuse it next time, and then perform auth only when really needed.
Additional context