Add date functions
This commit is contained in:
parent
ef08c699d6
commit
60574196b9
|
@ -1,4 +1,4 @@
|
|||
// import { addedHelpers } from "./helpers/external"
|
||||
const { date, duration } = require("./helpers/date")
|
||||
|
||||
// https://github.com/evanw/esbuild/issues/56
|
||||
const externalCollections = {
|
||||
|
@ -13,6 +13,11 @@ const externalCollections = {
|
|||
// uuid: require("@budibase/handlebars-helpers/lib/uuid"),
|
||||
}
|
||||
|
||||
const addedHelpers = {
|
||||
date: date,
|
||||
duration: duration,
|
||||
}
|
||||
|
||||
let helpers = undefined
|
||||
|
||||
const getHelperList = () => {
|
||||
|
@ -26,9 +31,9 @@ const getHelperList = () => {
|
|||
helpers[key] = func
|
||||
}
|
||||
}
|
||||
// for (let key of Object.keys(addedHelpers)) {
|
||||
// helpers[key] = addedHelpers[key]
|
||||
// }
|
||||
for (let key of Object.keys(addedHelpers)) {
|
||||
helpers[key] = addedHelpers[key]
|
||||
}
|
||||
return helpers
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue