Quick question about the Jade template engine :
node.js
variables to a .jade
template when you're not using express.js
?I'm trying to make a small website that doesn't use express, just so that I can understand how everything works.
Also, are there tutorials or articles about the use of Jade and node.js
without express ?
Thank you in advance !
var jade = require('jade');
jade.renderFile('tpl.jade', { hello: 'world' }, function(err, html) {
console.log(err);
console.log(html);
});
tpl.jade:
html
body
h1 #{hello}