Is it possible to configure the mime type returned by grunt-contrib-connect?
Stefany93 opened this issue · 1 comments
Stefany93 commented
I need to serve files without extensions as text/html
Stefany93 commented
SOLUTION:
options: {
port: 8800,
hostname: 'localhost',
middleware: function(connect, options, middlewares) {
middlewares.unshift(function(req, res, next) {
res.setHeader('Content-Type', 'text/html');
return next();
});
return middlewares;
},
}