Well,
SailJS\'s default templateing engine is EJS (Embedded Javascript)
But I cannot seem to find the place where we can create ou
solved: https://github.com/balderdashy/sails/issues/2162#issuecomment-55866731
config/http.js
module.exports.http = {
// ...
locals: {
filters: {
formatDate: function(date) { }
}
}
}
config/bootstrap.js
_.extend(sails.hooks.http.app.locals, sails.config.http.locals);
At some view...
views/test.ejs
<%=: created | formatDate %>