1.0.0 • Published 3 years ago
otdt v1.0.0
otdt
otdt
offers an alternative syntax for IIFEs.
It's an abbreviation of "on these, do this".
// The normal way:
// "A function that adds its two arguments shall be evaluated on 1 and 2".
((a, b) => a + b)(1, 2)
// The otdt way:
// "Evaluate, on 1 and 2, a function that adds its two arguments."
const e = require('otdt');
e(1, 2, (a, b) => a + b)
1.0.0
3 years ago