Quantcast
Channel: ReScript Forum - Latest posts
Viewing all articles
Browse latest Browse all 2592

Using open but for just one type?

$
0
0

Unfortunately, you can only do that with values, not types:

let {make} = module(User) (works)
type {t} = module(User) (does not work)

but I found out you can kinda do it with record spreads if the user type is a record.

type t = {...User.t}


Viewing all articles
Browse latest Browse all 2592

Trending Articles