express.use 메소드


express.use 메소드

app.use([path,] callback [, callback...]) 1. 패스가 지정되어 있지 않기 때문에 모든 경로에서 계속 호출 app.use(function (req, res, next) { console.log('Time: %d', Date.now()) next() }) 2. '/abcd' 경로에 들어왔을 때만 실행 app.use('/abcd', function (req, res, next) { console.log('Time: %d', Date.now()) next() }); 참고주소

express.use 메소드에 대한 요약내용입니다.

자세한 내용은 아래에 원문링크를 확인해주시기 바랍니다.


원문링크 : express.use 메소드