28 Jan 2023 |
lolgab#6138 | I tried and it doesn't seem to work in mixed Scala/Java projects | 16:44:48 |
lolgab#6138 | Can you open an issue in Mill? Does this work with Sbt? | 16:45:27 |
lolgab#6138 | I tried and it doesn't work in Sbt as well... Probably this is not supported by the zinc toolchain.. | 16:47:13 |
lolgab#6138 | If you switch to a JavaModule it works | 17:03:17 |
Override#2623 | i can't it's a scala module 🤔 | 22:51:14 |
Override#2623 | well didn't need module-infos finally | 22:51:29 |
29 Jan 2023 |
| 10.varunshah changed their display name from 10.varunshah to 10.varunshah#0212. | 07:31:10 |
| 10.varunshah changed their display name from 10.varunshah#0212 to 10.varunshah. | 07:31:15 |
| chuong joined the room. | 14:23:42 |
| ebo#9022 joined the room. | 15:05:05 |
ebo#9022 | Hi, this is a very outdated SO question but one that I think deserves some dusting off with fresh new answers:
https://stackoverflow.com/questions/35847332/best-way-to-convert-a-case-class-to-a-js-object
I've managed using trait or class that extends js.Object in my Scalajs code, and everything is happy until you really, really want a case class (e.g. for copy , equality checks, JVM support, macros, etc.)
So to that end, the options for converting case class into js.Object seem pretty limited... One person mentioned using uPickle but it got downvoted! Circe also has a fairly performant approach.
I get that you'll never beat the speed of native js.Object , but what do people recommend presuming speed is not everything? | 15:05:05 |
ebo#9022 | based on my own reading, it seems circe has generic.auto._ for automatic implicit serdes definitions, which is nice. Whereas with uPickle, it's documented as faster (even compared to circe-jawn ?) but requires explicit serdes defined in companion objects.
So, I'd lean towards the less code option (circe) but wanted to hear thoughts people have on this. Any other pros/cons to weigh in on the matter? | 15:09:22 |
armanbilge#6192 | even compared to circe-jawn
circe-jawn won't help in this case, it's for serializing/deserializing JSON, not js Objects | 15:24:56 |
armanbilge#6192 | however, you can look at circe-scalajs | 15:25:06 |
| Butanium joined the room. | 15:50:15 |
ebo#9022 | yes that's what I'm using. My understanding (from reading the code) is circe-scalajs serializes case classes to JSON then encodes as js.Object. So that's why I thought it would help.
And, thanks to you, I saw they recently merged circe-jawn as a replacement to JSON.parse 🙂 | 15:50:27 |
armanbilge#6192 | My understanding (from reading the code) is circe-scalajs serializes case classes to JSON then encodes as js.Object
yes, that's correct. basically, everything in Circe works with Json type. That is the common abstraction that the entire library is built around | 15:51:38 |
Override#2623 | Hey do you know a way to make mill print steps ? because they are useless in workflows | 20:27:36 |
Override#2623 |  Download image.png | 20:27:54 |
lolgab#6138 | Do you want to disable these prints? If yes, you can pass --disable-ticker to the mill cli | 20:34:19 |
Override#2623 | kay thanks | 20:46:09 |
Override#2623 | * okay thanks | 20:57:56 |
Override#2623 | * yes, thank you it worked 🙂 | 20:58:18 |
Override#2623 | * Hey do you know a way to make mill avoid print steps ? because they are useless in workflows | 20:58:38 |
30 Jan 2023 |
| EnglishGent joined the room. | 08:06:04 |
| Joeyh021 changed their display name from Joeyh021 to Joeyh021#4140. | 12:15:54 |
| Joeyh021 changed their display name from Joeyh021#4140 to Joeyh021. | 12:16:06 |
| SerenaSkov joined the room. | 14:48:15 |
| SpaceCowboy joined the room. | 15:50:59 |
| tryangul joined the room. | 21:31:26 |