Implement Middleware
Learn what middleware is, and practice how to use it.
We'll cover the following...
In the previous lesson, we used a middleware function, express.static()
, to serve static files to the client. We can use middleware functions for various tasks, such as logging, authentication, parsing data, and so on.
Middleware
Middleware functions are those that alter the request (req
) and response (res
) objects in the request-response cycle of an application.
New HTTP Request ...