Authentication logic changed

JWT is now stored in cookie instead of localStorage
changed APIs:
-> /api/auth/login
-> /api/auth/signup
new APIs:
-> /api/auth/logout
This commit is contained in:
Moon Patel
2023-07-23 13:20:55 +05:30
parent b2af52f2c6
commit 81ff9e31a0
5 changed files with 166 additions and 83 deletions
+3 -1
View File
@@ -14,6 +14,7 @@
"bcryptjs": "^2.4.3",
"body-parser": "^1.20.2",
"chess.js": "^1.0.0-beta.6",
"cookie-parser": "^1.4.6",
"cors": "^2.8.5",
"dotenv": "^16.3.1",
"express": "^4.18.2",
@@ -21,6 +22,7 @@
"mongoose": "^7.2.1",
"nodemailer": "^6.9.3",
"socket.io": "^4.6.1",
"uuid": "^9.0.0"
"uuid": "^9.0.0",
"zod": "^3.21.4"
}
}