There is a little problems with some of our functions.
const pickprop = (prop) => (obj) => obj[prop] ?? null;
const map = (f) => (ar...
For further actions, you may consider blocking this person and/or reporting abuse
Thank you for your question Eckehard, at first sight here is what I would do:
Demo
FInally you could write :
Demo
Thanks, to gave me the idea to include such a loop, in my micro lib :-)
Do you know a way to build a simplified but readable loop? Instead of for( let i=0; i<5; i++) fn(args)
Ideally it would be
loop(5) { ... }
We can do things like this, but this is far from ideal:
Demo
Hy Eckehard
Here is a possible answer.
If I find something clearer i will post it
Demo
Hy,
I´m not sure this works:
fn([...args].join('')? And you can call itloop(), as there is no loop keyword in JS. Anyway, a nice option.Here are 3 working versions
Demo
Eckehard, have you clicked on the démo link?
That works perfectly
Those functions can t be curried
I really liké the recursion way
The Demo works, but only with a single string parameter. Neither multiple arguments nor a numerical parameter seem to work.