• A brief history of ReasonML
  • Static Typing
  • Functional Paradigm
  • Compiling
  • Frontend Usage
  • Backend Usage
  • Conclusions

A brief history of ReasonML

Reason lets you write simple, fast and quality type safe code while leveraging both the JavaScript & OCaml ecosystems.

ReasonML is a new syntax for the OCaml programming languagecreated by Facebook.
If I had to describe OCaml in just a few words, I would say:

As you can see, these four arguments can create a lot of hype these days, where JavaScript libraries like React, Redux or new syntax like TypeScript, tries to increase JavaScript’s performance, maintainability and scaling.

ReasonML takes the advantages of both OCaml and JavaScript and can compile to both languages.

Compiling to JavaScript, thanks to the amazing BuckleScript compiler, means that you can run your ReasonML code on both browser and Node runtime.

Compiling to OCaml, means that your code can be compiled a second time to bytecode, assembly or native code.

ReasonML is a pretty new language, so it’s clear that still doesn’t have all the features you may need in order to write a complex application.
But there’s a good news: you can integrate both JavaScript and OCaml code in your ReasonML codebase, so you can take the advantage of using any npm library or write your own modules in OCaml.

Pretty impressive, isn’t it?

Did you like this article? Consider becoming a Patron!

This article is CC0 1.0 (Public Domain) licensed.