Closed bloodyowl closed 1 week ago
I remember seeing this on the forum, but I don't know how it was done in the end.
If there is no other context, I think it should be fixed. Let me look into it.
I just found https://github.com/rescript-lang/rescript-compiler/commit/639fcfd and seems @deriving(jsConverter)
for records is not supported since v11
@bloodyowl Can you share the code you're migrating and the compiler output (including errors/warnings)?
it's mostly for things like polymorphic variants:
@deriving(jsConverter)
type transport = [
| #api
| #csv
]
and records:
@deriving(jsConverter)
type site = {
id: string,
name: string,
token: string,
domain: string,
}
the errors are that the fromJs
& toJs
appear to be curried functions rather than uncurried ones
Fixed in recent uncurried work.
Hi!
When switching a project in uncurried mode, it appears that the
@deriving(jsConverter)
are output in curried mode. I'm seing that https://github.com/rescript-lang/rescript-compiler/issues/6492 handed@deriving(abstract)
, would it be possible to also apply this change tojsConverter
?