mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-18 16:09:03 +01:00
Initial
This commit is contained in:
parent
b6195127fe
commit
0c742eb91b
5 changed files with 200 additions and 131 deletions
|
|
@ -1,16 +1,20 @@
|
|||
export default class RegisterHandlebarsHelpers {
|
||||
static registerHelpers() {
|
||||
Handlebars.registerHelper({
|
||||
emptyObject: this.emptyObject,
|
||||
add: this.add,
|
||||
includes: this.includes,
|
||||
times: this.times,
|
||||
damageFormula: this.damageFormula,
|
||||
damageSymbols: this.damageSymbols,
|
||||
tertiary: this.tertiary,
|
||||
signedNumber: this.signedNumber
|
||||
tertiary: this.tertiary
|
||||
});
|
||||
}
|
||||
|
||||
static emptyObject(a) {
|
||||
return !a || typeof a !== 'object' || Object.keys(a).length === 0;
|
||||
}
|
||||
|
||||
static add(a, b) {
|
||||
const aNum = Number.parseInt(a);
|
||||
const bNum = Number.parseInt(b);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue