diff options
author | EuAndreh <eu@euandre.org> | 2024-02-25 06:46:52 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2024-02-25 06:46:52 -0300 |
commit | 1f0c90b9a34872c3a33ea12c6e5e329a1f98b213 (patch) | |
tree | b4522548f89a2abe28053d47748b0f9adee8c164 /src/utils.mjs | |
parent | Explicit import from "node:process"; move log() to hero.mjs (diff) | |
download | papod-1f0c90b9a34872c3a33ea12c6e5e329a1f98b213.tar.gz papod-1f0c90b9a34872c3a33ea12c6e5e329a1f98b213.tar.xz |
src/hero.mjs: Promote log() to fancy logger object
Diffstat (limited to 'src/utils.mjs')
-rw-r--r-- | src/utils.mjs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/utils.mjs b/src/utils.mjs index f2e09e4..c671f0f 100644 --- a/src/utils.mjs +++ b/src/utils.mjs @@ -76,3 +76,7 @@ export const first = (arr, fn) => { export const promisify = fn => (...args) => new Promise((resolve, reject) => fn(...args, (err, data) => err ? reject(err) : resolve(data))); + +export const partial = (fn, ...startArgs) => + (...endArgs) => + fn(...startArgs, ...endArgs); |