rescript-react-native / rescript-react-navigation

ReScript bindings for React Navigation
MIT License
74 stars 28 forks source link

Migrate to ReScript syntax #42

Closed MoOx closed 3 years ago

MoOx commented 3 years ago

Blocked by https://github.com/rescript-lang/rescript-compiler/issues/5104 (if we want to use bsb -format). Otherwise we should investigate if we could remove class (I have to admit I never really checked the reason, if they are mandatory or not and if we could rewrite bindings without using them - poke @cem2ran which wrote initial bindings in #20).

MoOx commented 3 years ago

They won't be added back into rescript syntax. I guess we could just use convert class type to records and external using @send if necessary.

cem2ran commented 3 years ago

I think this can be replaced with the object type spread from the latest version (9.1)

20210507_150319.jpg

cem2ran commented 3 years ago

@MoOx I did a quick test of my assumption. It does compile. Sooo it works right? :D I opened a draft PR.

Freddy03h commented 3 years ago

Hi @cem2ran ! I commented your PR, did you saw it?