{ "name": "docpad-plugin-handlebars", "version": "2.2.1", "description": "Adds support for the Handlebars templating engine to DocPad.", "homepage": "http://docpad.org/plugin/handlebars", "keywords": [ "docpad", "docpad-plugin", "handlebars", "templating", "templates", "render", "rendering" ], "author": { "name": "Mike Moulton", "email": "mike@meltmedia.com", "url": "http://meltmedia.com" }, "maintainers": [ { "name": "Mike Moulton", "email": "mike@meltmedia.com", "url": "https://github.com/mmoulton" }, { "name": "Benjamin Lupton", "email": "b@lupton.cc", "url": "https://github.com/balupton" } ], "contributors": [ { "name": "Mike Moulton", "email": "mike@meltmedia.com", "url": "https://github.com/mmoulton" }, { "name": "Benjamin Lupton", "email": "b@lupton.cc", "url": "https://github.com/balupton" }, { "name": "Tobias Birmili", "email": "birmili@mecodia.de", "url": "https://github.com/toabi" }, { "name": "Gilles Bouthenot", "url": "https://github.com/gbouthenot" } ], "bugs": { "url": "http://docpad.org/plugin/handlebars/issues" }, "repository": { "type": "git", "url": "https://github.com/docpad/docpad-plugin-handlebars.git" }, "dependencies": { "handlebars": "~1.0.10" }, "devDependencies": { "coffee-script": "~1.4.0" }, "engines": { "node": ">=0.4", "docpad": "6.x" }, "main": "./out/handlebars.plugin.js", "scripts": { "test": "node ./out/handlebars.test.js" }, "readme": "# Handlebars Plugin for DocPad\nAdds support for the [Handlebars](http://handlebarsjs.com/) templating engine to [DocPad](https://docpad.org)\n\nConvention: `.inlinejs|js|anything.handlebars|hbs|hb`\n\n\n## Install\n\n```\nnpm install --save docpad-plugin-handlebars\n```\n\n\n## Configuration\n\n### Getting helpers and partials to work\n\nFor the plugin to support helpers and partials, you'll have to add something like the following to your [docpad configuration file](http://docpad.org/docs/config) manually:\n\n``` coffee\n# ...\nplugins:\n\thandlebars:\n\t\thelpers:\n\t\t\t# Expose docpads 'getBlock' function to handlebars\n\t\t\tgetBlock: (type, additional...) ->\n\t\t\t\tadditional.pop() # remove the hash object\n\t\t\t\t@getBlock(type).add(additional).toHTML()\n\t\tpartials:\n\t\t\ttitle: '