Live data from Hacker News

Melange 1.0: Compile OCaml / ReasonML to JavaScript

buttondown.email

51–55 of 55 posts

Re: Melange 1.0: Compile OCaml / ReasonML to JavaScript

#51
post #44

Just a note, melange is also the name of a computer language workbench from INRIA ( http://melange.inria.fr/ ) and an APK builder ( https://edu.chainguard.dev/open-source/melange/overview/ ) Both of those came up before melange.re when searching for a hello world example.

Melange is the name of the desert spice that grants prescience in the Dune series, so this isn't too much of a coincidence.

This is also heavily inspired the name for this project.

Re: Melange 1.0: Compile OCaml / ReasonML to JavaScript

#53
post #34

As if the whole Reason/ReScript story wasn't complicated enough already :D First, we had BuckleScript, that compiled OCaml to JavaScript to bring the OCaml type system to the Web. Then we had Reason, that brought JS syntax to OCaml, so it's easier to grasp for JS devs. Seemingly, some people didn't care about OCaml at all, and forked (I guess?) Reason to ReScript, that focused on JS compilation. They also added a few…

Wasn't there also another OCaml-to-Javascript compiler called called js_of_ocaml?

There was and still is. It is actively maintained, works fairly well and has even recently been extended with support for multicore.

Re: Melange 1.0: Compile OCaml / ReasonML to JavaScript

#54
post #34

As if the whole Reason/ReScript story wasn't complicated enough already :D First, we had BuckleScript, that compiled OCaml to JavaScript to bring the OCaml type system to the Web. Then we had Reason, that brought JS syntax to OCaml, so it's easier to grasp for JS devs. Seemingly, some people didn't care about OCaml at all, and forked (I guess?) Reason to ReScript, that focused on JS compilation. They also added a few…

Wasn't there also another OCaml-to-Javascript compiler called called js_of_ocaml?

Indeed, and I believe it predates all the other ones by quite a bit.

Re: Melange 1.0: Compile OCaml / ReasonML to JavaScript

#55
post #41
post #10

I have nothing to say other than thank you! I might not use OCaml often myself, but I appreciate the effort to improve the ML ecosystem in any way :) I was a bit disappointed with the ReScript fork abandoning the compatibility with OCaml so this project was welcome news

I have only worked with ReScript for about a year before switching to ClojureScript (which was a better fit for my project), but I really enjoyed the experience and genuinely wish it would become a more popular alternative to TypeScript for devs who are coming from JS and are looking to dive into FP and static typing. The developer team did a great job with highly optimized and readable JS compilation, great integrat…

Good to hear they're providing a good dev experience. My only gripe at the time was more of a worry on whether the split was going to be worthwhile because the ML ecosystem is already so small, but I'm glad to hear the project has been effective for you.
Post reply on HN