I'm new into Node.js and trying to learn. From what I have understood it's common to use a template engine (eg. Jade), even for CSS (eg. Stylus). To be honest, all the tutorials I have seen out there involve a template engine when it comes to the layout.
The thing is that I don't want to use a template engine because I think it's unnecessarily complex.
Here is a link to a boilerplate for Node (unfortunately it doesn't work by some reason), but Option 1 shouldn't be using any template engine for the layout.
So, what is the easiest way to combine Node.js and Mongodb with "normal" HTML(5)? Is it possible for example to use HMTL5 Boilerplate with Node?
If you are using static html, so you wont need templating on the server side. You can easily serve your html files with Express/Connect static middleware, for example:
app.use(express.static(__dirname + '/public'));
then put an index.html
to your public folder.
Also I think you can copy and paste the whole h5bp to your public folder and it should work.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With