https://github.com/bhandarisachindev/NodeBackend.git day-11
Middleware functions are functions that have access to the request object (req), the response object (res), and the next() function in the application’s request-response cycle.
They can:
req and res objects.(req, res, next) => {
// Do something
next();
}
express.json())morgan, multer)const express = require('express');
const app = express();
app.use((req, res, next) => {
console.log('Time:', Date.now());
next();
});