These are chat archives for MetaStack-pl/MetaRx

14th
Sep 2015
Marius B. Kotsbak
@mkotsbak
Sep 14 2015 08:17
@tindzk yes, not a good solution, better provide a hardcoded solution for some number of parameters to zip() and look into Shapless like solutions for better solutions
@tindzk What about adding String + operator to ReadChannels, and scala.math.Ordering ? Or do you have plans for other meanings for that between the channels themself?
Tim Nieradzik
@tindzk
Sep 14 2015 08:52
@mkotsbak Perhaps we can come up with a trait Plus and several type classes for ReadChannel[String], ReadChannel[Seq[T]] etc. But I have doubts it is worth the effort because we will have to add more and more operators. We should provide another approach that lets us perform computations more easily on channels, something that combines map and zip.
Marius B. Kotsbak
@mkotsbak
Sep 14 2015 09:07
Japp, the need is endlessly, so it would only make sense for the simple cases
But the string case is quite common, and is solved when it is autoconverted to widget
Annoying that (progressCompleteness * 100).toInt + "%" returns a String, not ReadChannel[String] as expected
While this works: span((progressCompleteness * 100).toInt, "%")
Marius B. Kotsbak
@mkotsbak
Sep 14 2015 09:27
At least the boolean extras were extremely useful for code clearness: Button("Next").enabled(validator.valid && !isLoading).onClick { _ =>...
Tim Nieradzik
@tindzk
Sep 14 2015 09:55
Ok, you're right. We should restrict ourselves only to a couple of basic types.
Marius B. Kotsbak
@mkotsbak
Sep 14 2015 14:06
@tindzk you saw my PR?