Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom helpers needed #28

Open
MitchAnderson93 opened this issue Apr 2, 2024 · 1 comment
Open

Custom helpers needed #28

MitchAnderson93 opened this issue Apr 2, 2024 · 1 comment

Comments

@MitchAnderson93
Copy link
Member

MitchAnderson93 commented Apr 2, 2024

List of custom handlebars helpers to reduce code:

  • Ability to check (in handlebars) if a json object is true or false explicitly
    e.g. {{#if item boolean}} instead of {{#if item}}

  • Ability to compare two strings
    e.g. {{#isType this.value "value"}}
    // Done, added in QOL-100

  • Ability to calculate by X/determine end of row
    // Done, added in QOL-100

Examples we can re-use:

[QH helper modules](https://github.com/search?q=repo%3AQld-Health-Online-Team%2Fdesign-system+helpers&type=code&p=3)

@duttonw
Copy link
Member

duttonw commented Apr 16, 2024

Hi @MitchAnderson93 ,

do you think if its a good idea to split the handlebars out as a library npmjs module to be imported as they look generic enough to be its own module.

https://github.com/search?q=repo%3AQld-Health-Online-Team%2Fdesign-system+helpers&type=code&p=3

Your thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants