I am a beginner to express.js and I am trying to understand the difference between res.send and res.write ?
express.js
res.send
res.write
Content-Length
res.end()
app.get('/user/:id', function (req, res) { res.send('OK'); });
For more details:
response.write('<html>'); response.write('<body>'); response.write('<h1>Hello, World!</h1>'); response.write('</body>'); response.write('</html>'); response.end();
2.1m questions
2.1m answers
60 comments
57.0k users