Interface RedirectLoginOptions<TAppState>

Type Parameters

  • TAppState = any

Hierarchy

  • BaseLoginOptions
    • RedirectLoginOptions

Properties

appState?: TAppState

Used to store state before doing the redirect

authorizationParams?: AuthorizationParams

URL parameters that will be sent back to the Authorization Server. This can be known parameters defined by Auth0 or custom parameters that you define.

fragment?: string

Used to add to the URL fragment before redirecting

onRedirect?: ((url: string) => Promise<void>)

Type declaration

    • (url: string): Promise<void>
    • Used to control the redirect and not rely on the SDK to do the actual redirect.

      Example

      const client = new Auth0Client({
      async onRedirect(url) {
      window.location.replace(url);
      }
      });

      Deprecated

      since v2.0.1, use openUrl instead.

      Parameters

      • url: string

      Returns Promise<void>

openUrl?: ((url: string) => Promise<void>)

Type declaration

    • (url: string): Promise<void>
    • Used to control the redirect and not rely on the SDK to do the actual redirect.

      Example

      const client = new Auth0Client({
      async openUrl(url) {
      window.location.replace(url);
      }
      });

      Parameters

      • url: string

      Returns Promise<void>