README
Helpers
This repo contains the helpers that will be available to use in snippets. We'll take pull requests to add additional functionality as long as they're tested and formatted correctly.
Check out https://handlebarsjs.com/block_helpers.html
Adding a Helper
See helpers/dummy for an example helper
- Create a new directory under
./helpers
with the name of your helper. When your helper is loaded it will have the name of the directory. - Create
helper.js
,helper.test.js
, andREADME.md
in your helper directory - Export a function that has the same signature as a handlebars helper in
helper.js
- Write at least one
jest
test inhelper.test.js
to test your helper - Add required title, description, and example code in your
README.md
file
README.md
README.md
MUST follow the exact format in the example dummy helper since it will be used to generate docs on the site. Just copy the README and substitute the name, description, and example code. Don't change the header types/etc.