@webgo/auth-service-firebase
v0.0.13
Published
Firebase implementation of Auth Service
Downloads
4
Readme
⚠️ Work in progress do not use it yet.
Auth Service
Install
yarn add @codefulness/`
TODO: description
Usage
const authFirebaseService = require('auth-service-firebase');
// TODO: DEMONSTRATE API
Actions
if you pass the optional dispatch funtion to the constructor,
or inovoke auth.subscribe(dispatch)
AuthFirebaseSerivce will observe the user authication state,
and dispatch the following actions
AUTH_STATE_AUTHENTICATED
: when the user signs in successfully.
{
type: 'AUTH_STATE_AUTHENTICATED',
payload: { user: Firebase.User }
}
AUTH_STATE_UNAUTHENTICATED
:
{
type: 'AUTH_STATE_UNAUTHENTICATED',
}