MEVN Stack User Authentication - Full Tutorial

Martial Coding
Martial Coding
7.6 هزار بار بازدید - پارسال - Welcome to a full tutorial
Welcome to a full tutorial where we will be building a MEVN stack authentication app with JWT token and HTTP-only cookie support. This tutorial is perfect for those looking to learn more about MEVN stack and how to implement authentication within their web applications.

We'll start by covering the basics of MEVN Stack, which stands for MongoDB, Express.js, Vue.js, and Node.js. Then, we'll dive into the details of how we can use JSON Web Tokens (JWTs) and HTTP-only cookies to protect our users' data from unauthorized access.

Throughout the video, you'll see step-by-step how we can build a secure authentication system using these technologies. We'll also explain the benefits of using JWTs and HTTP-only cookies in this process, including how they can help to prevent cross-site scripting attacks.

By the end of our tutorials, you will have a better understanding of MEVN stack and how to implement an authentication system using JWTs and HTTP-only cookies. So sit back, relax, and let's get started on this exciting journey together!

Learn Authentication:
- Django & React Authentication with JWT - Django & React - JWT Authentication w...
- Best React Validation Practices - React Custom Form Validation - Best P...
- Responsive HTML & CSS card - Responsive Card Design (Gallery)

🔗 Source code: https://github.com/TuralHasanov11/mev...

🚩 Subscribe  ➜ @martialcoding3297

👇 Follow Me On Social Media:
My portfolio: http://turalhasanovportfolio.herokuap...
LinkedIn: LinkedIn: tural-hasanov-1a5554204
Follow me on GitHub: https://github.com/TuralHasanov11


00:00 Introduction
01:10 Installing Nodemon
02:45 Change package.json scripts
03:25 Setup index.js for Express app
05:55 Install npm packages
11:10 Configure CORS
15:45 Configure Database connection
18:40 Allow Credentials
21:40 Error Handler Middleware
23:33 Initialize Authentication Routes
26:35 Initialize Authentication Controller
29:40 Create default route handler for false endpoints
30:25 Create Database and initialize
33:25 Send test responses from controller
33:50 Fix allowed origins file
34:08 Fix error handler middleware
34:20 User model
40:22 Register function
49:10 Login
59:20 Logout
01:03:28 Add .exec() to DB calls
01:04:00 Continue Logout
01:07:30 Refresh token
01:16:35 Authentication middleware and get authenticated user
01:23:45 Auth middleware for authorizing the access the endpoints
01:27:33 Fixes
01:27:45 Testing all API endpoints
01:30:20 Creating Vue.js App
01:31:10Creating Views and Components
01:54:00 Create Auth Store
02:07:06 Create API handler composable
02:13:29 Using API composable inside store
02:27:27 Handle Register form
02:38:20 Handle Login form
02:41:10 Handle User data in User view
02:43:55 Handle User data in Navbar component
02:48:00 Calling getUser() action in User view
02:49:00 Fixing composable mistake in store
02:49:40Add frontend endpoint to allowed origins and fix middleware
02:51:36 Adding additional fields to Register form
02:53:00 Testing Register and Login forms
02:55:10 Fix store getter and state name mistake
02:56:20 Changing async setup to mounted hook
02:58:30 Setup persistent login
03:03:10 Creating additional API handler composable
03:06:30 Creating Navigation guards
03:10:45 Testing Application

Music 1 - Hayki ft. Patron - Bir Yol Göster Bana
Music 2 -  "BAD BOYZ" 90s Old school beat boom b...

#mevn
#stack  
#vue
#nodejs
#node
#express
#authentication
#cookies
#http
پارسال در تاریخ 1401/12/28 منتشر شده است.
7,622 بـار بازدید شده
... بیشتر