What are “res” and “req” parameters in Express functions?


In the following Express function:

app.get('/user/:id', function(req, res){
    res.send('user ' + req.params.id);

What is req and res? What do they stand for, what do they mean and what do they do?


request and response.

to understand the req, try out console.log(req);

This video can help you solving your question :)
By: admin