sol-auth 1.0.5 → 1.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +37 -12
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -9,45 +9,70 @@ Just import and use it in your project.
9
9
  # Install
10
10
  ---
11
11
  ``` npm i sol-auth
12
-
12
+ ```
13
13
  # Uses
14
14
  ---
15
15
 
16
16
  Import the package
17
17
 
18
- ``` const auth = require("sol-auth")
18
+ ``` const auth = require("sol-auth");
19
+ ```
19
20
 
20
21
  SignIn Option
21
22
 
22
- ``` auth.signIn({ username: username, password: pass, salt: salt })
23
+ ``` auth.signIn({
24
+ username: username,
25
+ password: pass,
26
+ salt: salt
27
+ });
28
+ ```
23
29
 
24
30
  LogIn Option
25
31
 
26
- ``` auth.logIn({username: username, password: password , hashPassword: hashPassword })
32
+ ``` auth.logIn({
33
+ username: username,
34
+ password: password,
35
+ hashPassword: hashPassword
36
+ });
37
+ ```
27
38
 
28
39
  LogIn with JWT Token
29
40
 
30
- ``` auth.logIn({username: username, password: password , hashPassword: hashPassword , payload , secret, expiresIn})
41
+ ``` auth.logIn({
42
+ username: username,
43
+ password: password ,
44
+ hashPassword: hashPassword ,
45
+ payload , secret, expiresIn
46
+ });
47
+ ```
31
48
 
32
49
  Examples
33
50
 
34
51
  ```
35
52
  const signInFunction = async () => {
36
- const signinData = await auth.signIn({ username: username, password: pass, salt: salt })
53
+ const signinData = await auth.signIn({
54
+ username: username,
55
+ password: pass,
56
+ salt: salt
57
+ });
37
58
 
38
- console.log(signData)
59
+ console.log(signData);
39
60
  }
40
61
 
41
62
  signInFunction()
42
-
43
- ```
63
+ ```
64
+ ```
44
65
  const logInFunction = async () =>{
45
66
 
46
- const loginData = await auth.logIn({username: username, password: pass , hashPassword: hashPassword })
67
+ const loginData = await auth.logIn({
68
+ username: username,
69
+ password: pass ,
70
+ hashPassword: hashPassword
71
+ });
47
72
 
48
- console.log(loginData)
73
+ console.log(loginData);
49
74
  }
50
75
 
51
76
  logInFunction()
52
-
77
+ ```
53
78
  ---
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sol-auth",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",