Provides additional helpers for Kinesis' apps.
https://github.com/ctcpip/ember-kns-helpers.git
Provides additional helpers for Kinesis' apps.
is-presentUses built in Ember.isPresent to check for presence.
{{#if (is-present someProp)}}
{{/if}}
โฌ๏ธ back to top
deep-equalChecks if two arrays contain the same items irrespective of what order they are in each array. Useful
for the All in a checkbox list.
{{input
type="checkbox"
checked=(deep-equal checkedYears organisationYears)}}
โฌ๏ธ back to top
format-blankShows the value is present, otherwise replaces it with default - or optionally provided replacement.
{{! Shows the default "-"}}
{{format-blank undefined}}
{{! Use something other than the default.}}
{{format-blank undefined "NA"}}
โฌ๏ธ back to top
format-booleanShows Yes/No for booleans.
{{format-boolean flag}}
โฌ๏ธ back to top
format-incrementSimply adds 1 to a number. Useful for showing collection indicies.
{{format-increment index}}
โฌ๏ธ back to top
format-percentageConverts a decimal percentage to a human readable percentage.
{{! Shows 10% }}
{{format-percentage 0.10}}
โฌ๏ธ back to top
index-ofReturns the index of an object in an array.
{{index-of item array}}
โฌ๏ธ back to top
To link your local package during development:
cd ~/Code/ember-kns-helpers/npm linknode_modules folder to the global symlink.cd ~/Code/project/npm link ember-kns-helpersnpm unlink ember-kns-helpersnpm installember-kns-helpers is MIT Licensed.