swint-middleware
Version:
Essential expressJS middlewares and general middleware loader for Swint
15 lines (11 loc) • 331 B
JavaScript
;
var swintHelper = require('swint-helper'),
path = require('path'),
serveFavicon = require('serve-favicon'),
defaultize = swintHelper.defaultize;
module.exports = function(options) {
options = defaultize({
iconPath: path.join(__dirname, 'favicon.png')
}, options);
return serveFavicon(options.iconPath);
};