Make a custom response class that makes accessing header info more native instead of writing to socket function.
So you can do something like this:
const route = serv.mount('/test) const route.get('/test2/', (req, res) => { const data = getInfo(); res.contentType = 'application/json' return data })
Make a custom response class that makes accessing header info more native instead of writing to socket function.
So you can do something like this:
const route = serv.mount('/test) const route.get('/test2/', (req, res) => { const data = getInfo(); res.contentType = 'application/json' return data })