
Create a React app with TypeScript template, build a chat UI using Material UI and icons, enable dark mode with a theme provider and container, and run on port 3000.
Implement GraphQL user create, read, update, and delete via bcrypt hashing of passwords, and updated inputs, using the user repository for create, read, update, and delete operations in MongoDB.
Fix the update user mutation by hashing the password only when provided, avoiding undefined password errors, and validate updates via login and credentials in GraphQL with bcrypt and JWT.
Create a useCreateUser hook with Apollo Client to execute the GraphQL createUser mutation from a createUserInput (email and password) and return the user’s id and email.
Configure nestjs jwt with a secret and expiration, create a token payload with id and email, generate a JWT, and set an HTTP-only authentication cookie.
Guard routes with an auth check and redirect to login on 401 GraphQL responses. Implement a logout link in Apollo that resets the store and navigates to login.
Learn to implement a logout feature by clearing the httpOnly JWT cookie via a backend /auth/logout route and refreshing the client store after redirecting to the login page.
Create a real-time chat backend using NestJS, GraphQL code-first, and Mongo, building chats module, chat entity, repository, and a create mutation guarded by authentication.
Generate type-safe GraphQL types for your React UI with the GraphQL code generator, watch for schema changes, and apply auto-generated types to a create chat mutation.
Retrieve and display chats in the app by implementing a chat resolver, creating a get chats hook, and using GraphQL fragments to fetch all chat data for the chat list.
Update the Apollo client cache after creating a chat by using useMutation's update, cache.modify, and writeFragment to append the new chat to the chats query and refresh the UI.
Implements a cleanup of the add chat flow by awaiting chat creation, closing the modal on success, removing dummy chats, and enforcing required chat name validation with error handling.
In this course, we go beyond the documentation & small simple starter apps to build a real-world full-stack chatting application. This application is built from the ground up to be scaleable & production-grade. The goal of the course is for you to be comfortable developing full-stack web apps so you can develop your own afterward.
We use a NestJS backend, a popular Node.js library that allows us to quickly create clean-code HTTP APIs. Our CRUD functionality will be served by a GraphQL API that persists data using a MongoDB database. We'll use this same GraphQL API to create our messaging subscription which allows for WebSocket connection to our UI to facilitate messaging. Of course, everything will be secured with industry-standard JWT auth.
On the UI we will create a React App using the beautiful Material UI to easily create a responsive UI and interact with our backend. We'll choose Apollo Client for state management so we can easily interact with our GraphQL API & cache data.
Finally, all of this will be deployed onto AWS Elastic Beanstalk & Amplify. Backed by a continuous delivery CI/CD pipeline, whenever we push code our latest changes will get built & deployed to our environment of choice.
By the end of the project, you will have learned everything you need to get started in building & deploying your very own production-grade web apps!