These are chat archives for ramda/ramda

22nd
Dec 2016
Scott Santucci
@ScottFreeCode
Dec 22 2016 05:43
Does @ram-bot support the newfangled "bind syntax"?
@ram-bot R.forEach(::console.log, [1, 2, 3])
ram-bot
@ram-bot
Dec 22 2016 05:44
Unexpected token :
Scott Santucci
@ScottFreeCode
Dec 22 2016 05:45
Ok; REPL it is then...
I have been experimenting a bit: https://goo.gl/seHm6V
Anyone have any thoughts on that?
Scott Santucci
@ScottFreeCode
Dec 22 2016 05:53
While it basically turns :: into a working pipe operator, I'm not sure it's any less verbose than R.pipe in the case when you want to give the pipe-based function a name and apply it to some data later. In fact, it seems a little more verbose. Which might demonstrate a limitation of :: with data-as-this functions for piping, compared to R.pipe with data-last functions.
Although on the other hand, I'm pleasantly amused that I got it to work in the first place.
Adam Szaraniec
@mimol91
Dec 22 2016 15:53
How can I remove empty values form object (key - value, type)
Brad Compton (he/him)
@Bradcomp
Dec 22 2016 16:09
@mimol91 filter will work on objects as well, would that help?
@ram-bot
filter(complement(isEmpty), {a: '', b: [], c: 'hello', d: [1, 2, 3, 4, 5]})
ram-bot
@ram-bot
Dec 22 2016 16:10
{ c: 'hello', d: [ 1, 2, 3, 4, 5 ] }
Denis Stoyanov
@xgrommx
Dec 22 2016 16:14
@ram-bot
reject(isEmpty, {a: '', b: [], c: 'hello', d: [1, 2, 3, 4, 5]})
ram-bot
@ram-bot
Dec 22 2016 16:14
{ c: 'hello', d: [ 1, 2, 3, 4, 5 ] }