router.get('/', **function(req, res, next)** {
res.send('Hello aumalls s')
//res.render('index', { title: 'Express' });
});
这后面的回调函数function(req,res,next){}
里面的参数是怎么肯定的,有几个参数,顺度是什么?这个我们怎么知道?
伊谢尔伦2017-04-17 16:07:07
A request object, a response object, and a next (if the function code in the callback is executed, you can enter the next middleware through next, otherwise it will always be in a suspended state), please refer to the official website demo for details