HACKER Q&A
📣 eboody

Why Isn't Rescript More Popular in JavaScript Community?


Hello HN!

Rescript, a programming language that compiles to JavaScript, has been on my radar for a while now. I'm particularly impressed by its strong typing, efficient performance, and readable JavaScript output, among other benefits that it carries over from its roots in OCaml and influences from Rust.

I've found that Rescript is potentially a strong fit for large-scale JavaScript projects, offering strong typing and a robust compilation system that can help catch errors early and enhance maintainability. However, despite its apparent advantages, I notice that Rescript isn't as widely adopted in the JavaScript community as one might expect.

In your opinion, what factors are contributing to Rescript's comparatively limited popularity?

Is it the steep learning curve for developers unaccustomed to statically typed languages, or is the broader JavaScript community just more inclined to stick with what they already know and use, like TypeScript, due to the level of tooling and community support available?

Is there an inherent barrier in adopting a language that transpiles to JavaScript instead of using JavaScript directly or are there certain use cases where Rescript may not be the best choice?

Lastly, how can we help elevate the perception and adoption of Rescript within the community?

I'm curious to hear your thoughts on this. Thank you for your insights!


  👤 johncoltrane Accepted Answer ✓
The supposed benefits you mention are not worth the headache for most of the things that are written in JavaScript.

For project that will be maintained for ten or twenty years? Maybe Rescript _or some other language with similar promises_. For projects with a six months shelf life or projects that will be rewritten in two years? No, thanks. And frankly, even TypeScript is too much for most of it.


👤 trinovantes
From a TypeScript dev perspective, there's just not enough (or any) tooling support compared to TS to justify switching to it. It doesn't seem obvious how it would work with eslint, jest, webpack/vite etc.

If people are not using TypeScript, then odds are they already made up their minds about typing in JS and will be even less likely to switch