app.use(function(req, res, next) { res.locals.__ = res.__ = function() { return i18n.__.apply(req, arguments); }; res.locals.user = req.session; res.locals.site = _config; res.locals.site.url_for = utils.url_for; res.locals.site.unitConvert = utils.unitConvert; next(); });
constructor() { this.__md = Markdown({ html: true, xhtmlOut: true, breaks: true, linkify: false, typographer: true }); this.__var = i18n.__; }