Logout

This action launches the logout process as defined in the Security Provider implementation.

It invokes the handleLogout function on the Security Provider with the logoutUrl argument.

This table describes the parameters for the Logout action:

Parameter Name Description
logoutUrl The URL to navigate to in order to logout. If not defined, uses the logout URL of the Security Provider configuration.
The behavior of the default implementation of the Security Provider handleLogout function is:
  • Navigate to the URL defined by the logoutURL parameter.

  • If the logoutUrl parameter is not defined, use the logout URL of the Security Provider configuration.

  • After the user is logged out, the application continues to the default page of the application.

Here's an example of a call to the Logout action:

await Actions.logout(context, {
     logoutUrl: $page.variables.logoutURL_pv,
});