These are chat archives for ramda/ramda
@paldepind I wasn't aware, but I think you're right.
I think it would be a minor change to
//dispatch to fl.map if on the obj, otherwise obj.map var f = obj[fl[methodname]] || obj[methodname]
But in practice ramda supports libraries that support fantasy land because they all expose
ap etc. I think it is more likely lodash would dispatch to
obj.map due to concerns of suprising dispatches.
But in practice ramda supports libraries that support fantasy land because they all expose map, of, ap etc.
Yes. But only because most libraries haven't been updated to the latest fantasy land spec either. Sadly, I don't think the fantasy land spec ever realized it's potential. I've seen a bunch of libraries that implement the spec but very little that actually use the abstractions.
With R.path is it possible to target all nodes in the array? I can do
R.path([‘schools’, ‘0’, ‘id’]) to get the id of the first school. What I like to do is to get all ids. Something like this:
R.path([‘schools’, ‘*’, ‘id’]). Is this possible?
R.mapto go through the array and then use
R.useWith(Math.pow, [() => 2, () => 3])(null, null);
const fn = R.converge(Math.pow, [() => 2, () => 3]) fn()
const fn = R.converge(Math.pow, [R.always(2), R.always(3)]) fn()
const fn = R.converge(Math.pow, R.map(R.always, [2,3])) fn()
Immutablemaps with the path supplied dynamically.
immutableMap.getIn(path)with the path supplied dynamically
groupByfunction, how can I group data based on Index. For example given
[a, b, c, d, e, f, g]I would like to get
[a, b], [c, d], [e, f], [g]. Is this possible?
aperturewon’t solve my problem. It gives you:
[[1, 2], [2, 3], [3, 4], [4, 5]]but I am looking for
[1, 2], [3, 4], . So just basically a function that split items into equal chunks.
filterwhich might do what I think you want to do
R.keysso you're aware of all the props
zipthem if need be.
Shifting frame pointers is, like, the most expensive thing in all of computing :laughing:
Real talk though, if you look at some of the Cry Engine code, they purposefully eschew separating their code into functions because the devs were scared of the frame pointer boogeyman.