Reason equivalent to Cargo or Mix?


#1

Is there a tool for Reason – like Cargo for Rust or Mix for Elixir – that simplifies common tasks like bootstrapping a new app, compiling code, or publishing a package? So far, I’ve been managing that through some combination of npm, reason-cli, and create-react-app with reason-scripts. Just wondering because I find tools like that really convenient in those languages.


#2

There’s a bsb cli tool that comes with global bs-platform installation and takes care of builds and app scaffolding.

As for dependencies, you can use OCaml deps, NPM deps and whatnot, so there’s not a single tool (yet?) to manage them all.

In that way, life is simpler in the land of Elm. Elm author(s) approach to rely on a growing set of quality packages written in pure Elm. There, you supposed to interact with JS only if you really, really have to. So elm-package is enough most of the times.

ReasonML goal is to be easily introduced into existing JS codebase, so it has to be compatible with NPM. And since it wasn’t born with an impressive standard library (both BuckleScript and ReasonML proper are done by small teams), opam compatibility is very important too. None of it makes the packaging situation very simple.


#3

There is a tool that’s under development but totally usable today. It’s called esy


#4

The way I understand, esy is for native development only, so I haven’t given it much thought. But it does sound great.


#5

Yup, esy isn’t yet suitable for web development (afaik), but the end goal is for it to be a complete system, a la cargo


#6

last time I discussed this, what prevent esy from being one is the install hooks (preinstall, postinstall) and packages could break esy’s sandbox with those hooks


#7

I mean also it doesn’t work with bsb? (it will with bsb-native, but only in native compilation mode)


#8

Is it done in sync with the people from Cambridge who are working on the ocaml platform?