pratech-library-b2c
v1.1.1
Published
App de autenticacion para la vistas de react
Downloads
6
Readme
Pratech Products Authentication Front B2C
Installation
Node.js v8+ para instalar.
Install the dependencies and devDependencies and start the server.
$ npm i pratech-library-b2c
Ejemplo de uso
import { AuthPratech } from 'pratech-authentication-b2c';
para utilizar la autenticacion con B2C en el front :
Ejemplo
const msalConfig: any = {
auth: {
clientId: 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxx',
authority:
'https://xxxxxxxx.b2clogin.com/xxxxxxxx.onmicrosoft.com/B2C_1_sign_in',
validateAuthority: false,
},
cache: {
cacheLocation: 'localStorage',
storeAuthStateInCookie: false,
},
};
const loginRequest: any = {
scopes: ['openid', 'profile'],
};
<AuthPratech
titulo="Ingresar"
clase="login"
configuration={msalConfig}
loginRequest={loginRequest}
onExistLogin={(response: any) => resquestSuccess(response)}
/>