I'm pretty disappointed with the way this has unfolded.
For those now familiar with ReScript, ReScript started as "reason" an alternative syntax for Ocaml. Recently ReScript was created with a sytnax more similar to TypeScript than "Reason". In addition, there is a fork of OCaml for compiling to javascript that used to be branded as "Bucklescript", but now it is called "ReScript" as well.
So now as of 12/14/2020 there are three Ocaml syntax versions in use:
Ocaml,
Reason (Reason 3.6, last version available for native code)
ReScript, (~Reason 4, only available for javascript compiler fork, some sytax present in Ocaml/Reason has actually been removed with no equivilant in the grammar)
I am not sure who benefits from this, Ocaml is a serious language that will never be as simple as a dynamically typed language. I am not sure who this is supposed to be helping. It seems to me that things were more clear a year ago when there were just two syntaxes available. In addition, it now takes a relative subject matter expert to disipher what is going on, which i think is the exact outcome ReScript was trying to avoid.
I am very disappointed by this as well. I am worried ReScript may have killed the momentum ReasonML had been gaining.
This is how I understand this:
1996 - OCaml is born.
2016 - ReasonML, an alternative syntax that compiles to OCaml, is launched by Facebook.
2016 - A couple of months later, BuckleScript, an OCaml -> JS compiler is launched.
201X - Collaboration happens, BuckleScript couples tightly to ReasonML.
2020 - BuckleScript forks the ReasonML syntax and rebrands the compiler and the new syntax together under ReScript.
2020 - ReasonML still exists?
Ok, fine. What is not clear to me is how the Facebook team behind ReasonML fits into ReScript. Are they aligned on the direction to take this community? What is the future of ReasonML?
What was the goal? If it was to ease adoption by newcomers, as a newcomer, it has made this more difficult. As someone VERY EAGER to enter this family of languages today, I ended up giving up on all of that and decided to just learn OCaml.
Now I'm dealing with Dune, Esy, OPAM, two competing async libraries and a community that is split between Jane Street libraries and the others.. but I really, really like OCaml!
This feels a lot like what happened to Hack, which at first was compatible with PHP and could be compiled to it, but later became its own language to better fit FB's needs, and it seems like they're giving OCaml the same treatment here with ReScript.
There was actually some effort being made to keep OCaml tooling compatible with ReasonML (which is supported by dune[0] with no additional configuration) and BuckleScript integration with dune, which was being worked on before this rebrand, so it's kind of sad to see FB going off on their own with ReScript because they don't wanna do the work to upstream the changes they need.
By the way, regular OCaml also has its own JS backend[1] which is of course completely incompatible with BuckleScript.
Feeling the same about this. Things were far clearer prior to this year -- I can no longer really see the point of the project and I'm just a bit sad about how it's all evolved. I've been following it since just before FB came in with ReasonML. I'd just started playing around with OCaml, found Bucklescript (which I still think is a marvel). Reason seemed like a way [albeit via that syntax] to get some traction for a very good language that imo seriously lacks in community, libraries and documentation. It felt slightly like Elixir, filling in a few holes in the underlying language and adding a layer of consistency. And it seeed a very good alternative to TS. But instead of coalescing into something, it seems to have just fragmented things further
I hope something good does coalesce, but it's currently very confusing. Maybe just me but the opportunity feels like it's slipping away. As say, been following things very closely so I fully appreciate some the issues & understand some hidden things are based on internal needs of that part of FB
I'm rather confused: what is ReasonML ? is ReasonML now ReScript, or is it still its own thing? A quick google suggests ReasonML is for targeting native platforms? But I used it for the web at one point?
Anyway, there was already a problem with like three different standard libraries (which had super annoying differences like swapping parameter orders, presumably in an attempt to be friendlier etc.) or something when I first messed around with ReasonML (Bucklescript? Whatever the Facebook one was in 2019? I dunno.) and I hope this isn't also increasing that problem ?
Moreover it's hard to figure out which Ocaml version is Rescript on? Last i checked it was on 4.06, Do they backport any features, bugfixes?
Now it seems like it's a complete fork with a new syntax. Maybe it serves the interest of people at facebook, but Ocaml users are unlikely to be using this instead of js_of_ocaml.
I want to write my front end and back end in the same language - Reason - and compile the backend to native code. So, ReScript doesn’t work for me? Are people still using or working on Reason, or is it dead?
I feel like this fork might make sense inside Bloomberg, but it’s killed my enthusiasm for this language family.
Theoretically, ReScript will support ReasonML syntax, and theoretically ReasonML can still be used for native development.
The messaging isn't clear on ReasonML's future at ALL though. Is it essentially deprecated until the full switch to ReScript happens? The Rescript FAQ mentions changes will be additive in supporting ReasonML, and they will track new features to OCaml, but will they track new features to Reason? Will anyone actively develop Reason anymore?
You might have been able to use the same syntax before, but writing code for Reason native was already very different to writing Reason+BuckleScript for the browser. This just formalises the split.
To write the same code for both front and back end js_of_ocaml has been the standard since long before Reason came along, and it works just fine with Reason native.
actually bucklescript has never really been used at bloomberg. And bob left bloomberg a long time ago. So this fork is definitely not happening because of bloomberg.
To have code that you can compile to both native and js, the easiest thing is to stick to the ocaml syntax. It is supported by all the versions of the compiler (rescript or ocaml). And to also use the ocaml syntax for the tools doing code generation, such as atdgen.
You should give F# a try. Check out Feliz [0], it integrates flawlessly with React and you can use elmish for the internal state management of components. You can use F# on the backend as well (Giraffe, Saturn) and use Fable.Remoting for RPC.
We aren't sure when we will be able to open source the new model, and we are still using Reason syntax with the ReScript compiler, but we will transition to ReScript syntax eventually.
Btw for people who want to use js_of_ocaml instead of rescript but still like react, there is https://github.com/jchavarri/jsoo-react. It's obviously not as polished. But it's interesting to see how much work it requires to bind a large lib like react.
I know Reason/Rescript was to make OCaml's type system available to the JS devs and is an excellent alternative to typescript but its quite hard to follow. I'm a JS developer with no experience in statically typed languages. I'm not able to figure out what exactly is the way to do things we usually do in JS ecosystem. I mean things like a package manager, build system. These things are confusing. I'm pretty sure that there are tons of people turned away from Reason for this very same reason.
Also OCaml in Windows was hard to configure and get right. The barrier to entry into the ecosystem is huge and it has to be resolved. The language is beautiful but anyone needs to be able to get productive in it very quickly.
[+] [-] bgorman|5 years ago|reply
For those now familiar with ReScript, ReScript started as "reason" an alternative syntax for Ocaml. Recently ReScript was created with a sytnax more similar to TypeScript than "Reason". In addition, there is a fork of OCaml for compiling to javascript that used to be branded as "Bucklescript", but now it is called "ReScript" as well.
So now as of 12/14/2020 there are three Ocaml syntax versions in use:
Ocaml, Reason (Reason 3.6, last version available for native code) ReScript, (~Reason 4, only available for javascript compiler fork, some sytax present in Ocaml/Reason has actually been removed with no equivilant in the grammar)
I am not sure who benefits from this, Ocaml is a serious language that will never be as simple as a dynamically typed language. I am not sure who this is supposed to be helping. It seems to me that things were more clear a year ago when there were just two syntaxes available. In addition, it now takes a relative subject matter expert to disipher what is going on, which i think is the exact outcome ReScript was trying to avoid.
[+] [-] n42|5 years ago|reply
This is how I understand this:
Ok, fine. What is not clear to me is how the Facebook team behind ReasonML fits into ReScript. Are they aligned on the direction to take this community? What is the future of ReasonML?What was the goal? If it was to ease adoption by newcomers, as a newcomer, it has made this more difficult. As someone VERY EAGER to enter this family of languages today, I ended up giving up on all of that and decided to just learn OCaml.
Now I'm dealing with Dune, Esy, OPAM, two competing async libraries and a community that is split between Jane Street libraries and the others.. but I really, really like OCaml!
[+] [-] steinuil|5 years ago|reply
There was actually some effort being made to keep OCaml tooling compatible with ReasonML (which is supported by dune[0] with no additional configuration) and BuckleScript integration with dune, which was being worked on before this rebrand, so it's kind of sad to see FB going off on their own with ReScript because they don't wanna do the work to upstream the changes they need.
By the way, regular OCaml also has its own JS backend[1] which is of course completely incompatible with BuckleScript.
0: https://dune.build/ 1: https://github.com/ocsigen/js_of_ocaml
[+] [-] RobertKerans|5 years ago|reply
I hope something good does coalesce, but it's currently very confusing. Maybe just me but the opportunity feels like it's slipping away. As say, been following things very closely so I fully appreciate some the issues & understand some hidden things are based on internal needs of that part of FB
[+] [-] banjomet|5 years ago|reply
[0]: https://github.com/revery-ui/revery [1]: https://onivim.io/
[+] [-] giantDinosaur|5 years ago|reply
Anyway, there was already a problem with like three different standard libraries (which had super annoying differences like swapping parameter orders, presumably in an attempt to be friendlier etc.) or something when I first messed around with ReasonML (Bucklescript? Whatever the Facebook one was in 2019? I dunno.) and I hope this isn't also increasing that problem ?
[+] [-] xfer|5 years ago|reply
Now it seems like it's a complete fork with a new syntax. Maybe it serves the interest of people at facebook, but Ocaml users are unlikely to be using this instead of js_of_ocaml.
[+] [-] jitl|5 years ago|reply
I feel like this fork might make sense inside Bloomberg, but it’s killed my enthusiasm for this language family.
[+] [-] unknown|5 years ago|reply
[deleted]
[+] [-] merlinsbrain|5 years ago|reply
The messaging isn't clear on ReasonML's future at ALL though. Is it essentially deprecated until the full switch to ReScript happens? The Rescript FAQ mentions changes will be additive in supporting ReasonML, and they will track new features to OCaml, but will they track new features to Reason? Will anyone actively develop Reason anymore?
[+] [-] spyder81|5 years ago|reply
To write the same code for both front and back end js_of_ocaml has been the standard since long before Reason came along, and it works just fine with Reason native.
[+] [-] testcross|5 years ago|reply
To have code that you can compile to both native and js, the easiest thing is to stick to the ocaml syntax. It is supported by all the versions of the compiler (rescript or ocaml). And to also use the ocaml syntax for the tools doing code generation, such as atdgen.
[+] [-] davesnx|5 years ago|reply
[+] [-] chubot|5 years ago|reply
I was searching for this recently and came up short... Is it mainly being used inside Facebook?
Kind of a shame as the ideas look good. I would like something like Elm, but Elm doesn't interoperate with JS.
[+] [-] gdotdesign|5 years ago|reply
You can try Mint: https://www.mint-lang.com
I've created it because I wanted something like Elm but with easier JS interop and less boilerplate :)
[+] [-] angio|5 years ago|reply
[0] https://github.com/Zaid-Ajaj/Feliz [1] https://github.com/Zaid-Ajaj/Fable.Remoting
[+] [-] rienbdj|5 years ago|reply
[+] [-] spyder81|5 years ago|reply
https://www.tiny.cloud/blog/tinymce-reasonml/
We aren't sure when we will be able to open source the new model, and we are still using Reason syntax with the ReScript compiler, but we will transition to ReScript syntax eventually.
[+] [-] testcross|5 years ago|reply
[+] [-] testcross|5 years ago|reply
[+] [-] davesnx|5 years ago|reply
[+] [-] jesperlang|5 years ago|reply
This issue is trying asking for some explanation regarding the future of ReasonML. Maybe comment/react/subscribe to stay up to date on this issue!
[+] [-] vijaybritto|5 years ago|reply
Also OCaml in Windows was hard to configure and get right. The barrier to entry into the ecosystem is huge and it has to be resolved. The language is beautiful but anyone needs to be able to get productive in it very quickly.
[+] [-] lnyan|5 years ago|reply
[+] [-] spyder81|5 years ago|reply