Express is a module that provides additional methods that make working with websites easier. Most of the main express functionality is stored inside the express() function which provides several methods to take care of common http tasks. It's definitely easier to do things with express than with NodeJS.
- [Voiceover] In the last video I showed you…how to create a simple server with Node.js.…In this video I'm gonna show you…how to do the same thing with Express.…Now Express is a module that provides additional methods…that make working with websites easier.…Just like with the HTTP library…you start by requiring the Express library,…and this isn't a default library like HTTP,…so we do have to install that in our Node modules folder.…We did that in the chapter on installing requirements.…So all we have to do now is…use the require command to bring in the library.…
Now most of the Express functionality…is stored inside an Express function,…so we can create an instance of this function…and assign it to a variable…to make things easier to work with.…One of the advantages of using Express…is that we don't have to worry about mime types.…That's all gonna be taken care of for us…and it also provides easy routing…so that we can build an application a lot quicker.…So let's take a look at how we do this in our application.…
In this course, Ray Villalobos walks through the process of creating full-featured websites with these technologies. First, find out how to install each package and leverage Node.js features from within Express. Then learn how to build a basic application with templating engines like EJS; create more flexible, modular code with includes and conditional statements; build APIs to manage HTTP requests to add and delete content dynamically; and configure more complex routing. Along the way, Ray implements features like customer feedback forms and real-time live chat, so you can see exactly what Node.js and Express are capable of.
- Handling HTTP requests with Node.js and Express
- Creating and modularizing routes
- Using templates
- Building flexible views
- Creating an API route
- Dealing with POST and DELETE requests
- Creating live chat features with Socket.IO