Express websocket9/11/2023 Let's begin now that you know the basics of ExpressJS and how to validate a user response. If you like this tutorial kindly leave a star on the github repository. If you have any feedback, please just reach out to me on. The entire source code of this tutorial can be found here. Īnd here's the make-validation library link. Here's the GitHub link to the entire source code of this video. In the below video, you'll learn how to write your own custom validation using a library called "make-validation": Adding API validation to your API end-point It has all the relevant learning links I mention in the video along with an amazing half hour tutorial on postman. I talk about all this and more (including REST conventions) in this video:Īlso, here's a GitHub link to the entire source code of this video ĭo have a look at the README.md for "Chapter 0" source code. What are routes? Controllers? How do we allow for CORS (cross origin resource sharing)? How do we allow enduser to send data in JSON format in API request? Delete a chat room by id along with all its associated messagesīefore we begin, I wanted to touch on some basics in the following videos.Get recent conversation from all chats (similar to Facebook messenger).Mark an entire conversation as read (similar to Whatsapp).See conversation for a chat room by its id.Discussing chat room & chat message database model.Web socket class that handles events when a user disconnects, adds its identity, joins a chat room, wants to mute a chat room. JWT (JSON web tokens) authentication (decode/encode) - Login middleware.Creating users API + Database (Create a user, Get a user by id, Get all users, Delete a user by id).Setting up MongoDB (installation, setup in express).Create basic skeleton for the entire application.Install Node/NPM on your machine (I am using Node version v12.18.0).For Linux users, you can find the installation guide.For macOS users, you can find the installation guide.For windows users, you can find the installation guide.I have been working on the content for this article for over a week now – I really hope it helps someone out there. Have you ever wondered how chat applications work behind the scenes? Well, today I am going to walk you through how to make a REST + Sockets-based application built on top of NodeJS/ ExpressJS using MongoDB.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |