22 lines
264 B
JavaScript
22 lines
264 B
JavaScript
//middleware
|
|
|
|
|
|
/*
|
|
const myLogger = function (req, res, next) {
|
|
console.log('LOGGED')
|
|
next()
|
|
}
|
|
|
|
// Apply the middleware to a specific route
|
|
app.use('/special-route', myLogger));
|
|
|
|
*/
|
|
|
|
const APIlogger = (req, res, next) => {
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = { APIlogger } |