Hi, I've asked a similar question before, and also resolved it myself here:
ESRI JS API: IdentityManager: how to use localStorage
This was for the scenario, where I've used the popup: true for the OAuth2.0 authentication.
However, I'm now in the scenario where I have to use redirect to the agol's/portal's oAuth page insteas of a popup, so I have to use the popup: false.
This seem to work fine, but the problem is that user has to approve the access each time he opens the app, because the oath state is stored in session-storage in esriJSAPIOauth property, instead of local-storage. I guess this all happens as there is no presence of any 'Keep Me Signed In' or similar checkbox for the enterprise login oAuth page.
Does anyone know how can I force the IdentityManager to store the redirected oauth state into the session-storage ?
Thank you.
ESRI JS API: 4.14
AGOL/PORTAL SECURITY: Enterprise logins