1.0.8 • Published 3 years ago

useauthrocket v1.0.8

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

authrocket

Installation

npm install useauthrocket

Usage

 import Authrocket from 'useauthrocket'
    
 const app = Authrocket.initializeApp({
           apiKey: <your api key>,
           appName: <your app name>
    })

Visit authrocket website to generate an api key. appName is the name of your application and can be anything

Available methods

  • createAccount
    • accepts:
      • email (string)
      • password (string)
      • payload (object)(optional)
    • returns: object
    const user = app.createAccount(<email>, <password>, <payload>)
* login
    - `accepts`: 
        - email (string)
        - password (string)
    - `returns`: object
 ```js
 const user = app.login(<email>, <password>)
  • getUser
    • accepts:
      • uuid (string)
    • returns: object
    const user = app.getUser(<uuid>)
 
* isEmailVerified
    - `accepts`:
        - uuid (string)
    - `returns`: boolean
 ```js
 const isEmailVerified = app.isEmailVerified(<uuid>)
  • isUserLoggedIn
    • accepts:
      • uuid (string)
    • returns: boolean
    const isUserSignedIn = app.isUserSignedIn(<uuid>)
 
* signout
```js
 app.signout()
1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago