Answers for "expressjs file response"

0

express return html file

//res.sendFile(path [, options] [, fn])
app.get('/test', function(req, res) {
    res.sendFile('test.html')
});
Posted by: Guest on February-08-2022

Browse Popular Code Answers by Language