npm.io
10.4.1 • Published 6d ago

@volo/abp-react-oidc-auth

Licence
LGPL-3.0
Version
10.4.1
Deps
1
Size
6 kB
Vulns
0
Weekly
1.3K

Description

@volo/abp-react-oidc-auth provides React integration helpers for @volo/abp-oidc-auth.

Install

npm i @volo/abp-react-oidc-auth @volo/abp-oidc-auth

Usage

import { createAbpReactOidcAuth } from '@volo/abp-react-oidc-auth'

export const auth = createAbpReactOidcAuth({
  authority: 'https://localhost:44301/',
  clientId: 'MyProjectName_App',
  redirectUri: window.location.origin,
  postLogoutRedirectUri: window.location.origin,
  scope: 'offline_access MyProjectName',
})
function AppRoot() {
  return <auth.AuthProvider>{/* app */}</auth.AuthProvider>
}

Keywords