appState
parameter for the loginWithRedirect()
method. Details about the current app are packaged as part of the request to the Auth server that will be returned upon successful authentication. Allowing a seamless continuation of the user journey.
In the Quickstart, the PrivateRoute
component sets a state parameter of targetUrl
and the onRedirectCallback
function of index.js
unpacks this value to redirect the user when authentication is complete.
getTokenSilently()
method is used to leverage the token cache first, and if none exists, will launch an invisible iframe to retrieve a new token. For this purpose all requests to APIs can use this method to construct the bearer token header without the need for additional logic to handle for expired tokens.
In the Quickstart, the ExternalService
view makes a request to the express API using this feature.
getTokenSilently()
called
getTokenSilently()
called
isAuthenticated()
loginWithRedirect()
getTokenSilently()
logout()
called
/oidc/logout
getTokenSilently()
called