node-boiler
node-boiler copied to clipboard
Using hbs templates and view engine
Using hbs for dynamic page rendering in place of static pages.
Having the following error in the forked project in the test-dev branch on running "sudo nodeboil"-
TypeError: templates.map is not a function at Object.makeTemplates (**/node-boiler-dev/lib/helpers/fileGenerators.js:33:22)
code -
makeTemplates: function(templates) { return templates.map(item => fsWritePromisified(
./templates/${item}.hbs, contetMaker.templateContent(item)) .then(successHandler(
${item}.hbs)) .catch(errorHandler) ); },
Error shows up when boil.yml has the following included and old views key commented out-
templates: partials: - 'header' - 'footer' views: - 'home' - 'profile'
link to the forked project:- https://github.com/sarthakpranesh/node-boiler/tree/test-dev