State of ReScript compiler/Roadmap

Hey folks,
I know the community around other projects is alive. but the compiler seems to have died down the past months and the roadmap seems to be not relevant.
Could we get an update?

6 Likes
6 Likes

I hope @Hongbo will be able to take a breath on parental leave (especially as it’s not time to chill usually) but to be honest (at least from my point of view) Rescript is production-ready, and it’s an awesome replacement for Typescript right now :grinning_face_with_smiling_eyes:

6 Likes

100% :slight_smile:
As someone with a 9m old child i can definitely agree that parental leave is super important.
BUT, i think the elephant in the room here is that once 1 person is OOO the entire work on the compiler puts on halt. I don’t mean to complain about that, @Hongbo did an AMAZING job at building the compiler - But, i think part of maturing a compiler is trying to make yourself, somewhat, redundant.

As someone building a company on top of ReScript - this lights some red-flags - What if @Hongbo will stop caring about ReScript in 3 months? will it go the route of CoffeeScript?

I think we as a community should discuss these concerns in an open manner.

10 Likes

I can’t explain core team choices, but I can share my experience with proposing Rescript for clients because the fact that there is a single person responsible for the compiler and he is on a long break probably would be a bright red flag… but it never came to that point.
The biggest concern for clients about Rescript is low adoption and the lack of developers on market. The biggest selling point for me is better maintainability compared to Typescript, better support for FP features (I summed it up here) and far better FFI compared to alternatives, but for business what matter is if it can replace the developer after 2-4 years, and typescript is safe to pick here.

So… Rescript is a niche language and its real competitor is Elm. There are other alternatives like PureScript, ClojureScript, Scala.js, js_of_ocaml, but out of these exotic alternatives to JS/TS IMHO, only Elm is production-ready on a large development scale while also battle-tested. Its last release was in 2019 with active community, and language is hugely influenced by its creator. There is also not a lot going on in Purescript or ClojureScript repos.
The point for the compiler is to hit the sweet spot, and in my opinion, Rescript is close.
Having a single person responsible for a compiler is a big leap of faith, but not necessarily a bad thing. It allows technology to be more opinionated which might have great results (like with Elm). With community-based development, technology may not reach its production-ready state ever (as it might happen for Yew).

Summing up, the problem you highlighted might be breaking, but for most companies, it won’t be the main problem.

7 Likes

By the way if you take a look at the roadmap the next release is scheduled on January Roadmap | ReScript Community

Well there is Melange, which is being actively developed as far as I can tell, plus it’s already been rebased on top of the latest OCaml 4.14. So one way or another users should still have options.

But as usual in open source projects, the best way to ensure continuity is for someone to step in and actually pay people to work on it. It would be great to see the community discussing how to do that.

5 Likes

I would happily help sponsoring the compiler work. The thing is, decision-making is still very centralized so the community can’t take a lead in that. This is something that Bob himself has to set up in order to work.

8 Likes

I would also be super happy to sponsor the compiler work - i honestly think that this is more about “giving away one’s legos” - e.g Bob has to understand that for a language to mature things needs to change - which means it’s not just about him doing all the decisions(or, tbh, any governance model that’s not a single point of ownership).
I’m not sure if the situation with Melange is better, will explore.

2 Likes

Well, Purescript community is gearing up for a bigger release and while it’s not used by any big corporations (that I know of) there are certainly quite a few companies using it (even in my small country).

Anyway, I’m advocating for ReScript adoption in our company because I think people could learn it pretty quickly and it provides a lot of benefits. I wish there were more ReScript videos on Youtube and a book or two… those could make it feel more legitimate.

1 Like

I think the ReScript Association / ReScript team was formed to address this exact issue, no? Perhaps someone can engage with them about sponsored development work and roadmap? If they are unresponsive to that, then perhaps indeed it would be time to look elsewhere.

4 Likes

As I see it right now, all the talks are made by users, not owners.
Maybe some owners could participate and explain all the pain points of the community ?

I know it’s a touchy subject, but should it be ?

I thinks that, without clear explanations from the owners team about the problems and the possible solutions, we gonna get a thread exactly like this one every 2 weeks.

No anger in this post, only hope for further discussions about real subjects, concerning that wonderful langage :slightly_smiling_face:

4 Likes

but the compiler seems to have died down the past months and

Hi, thanks for bringing this up. I am close to finishing my parental leave, so that I will start to work on it in the next few weeks.

the roadmap seems to be not relevant.

There is no funding for this project any more, so it is expected that the contribution will be less than before.

There are two main features that I want to add before considering the language mostly finished.

The first is a new pattern match compiler so that it will give us more freedom for data type encodings, for example:

@unboxed
type number_or_string = 
  | Float (float) | String (string) 
// this should be unboxed

@string // encoding as "A" | "B" | { type: "C" ,  _0 : int}
type t = 
   | A 
   | B 
   | C (int)

I had a working prototype but make it production quality takes some time.

The other thing is uncurry by default, this is technically trivial but
would have a non-trivial impact on existing code.

@yawaramin

Well there is Melange, which is being actively developed as far as I can tell, plus it’s already been rebased on top of the latest OCaml 4.14. So one way or another users should still have options.

Keep advocating such hostile fork actually get me demotivated to work on it, it is disgraceful to my hard work in the past 7 years. The fork does not really add any meat except introducing subtle regressions and make the community fragmented.

Note I am more than happy to give commit rights if we can find reliable contributors who share similar visions.

17 Likes

Thank you for your reply @Hongbo, but tbh, that’s part of the issue i guess :slight_smile:
Knowing that when/if you get mad, a tech stack i rely on might not get updates is something i’m not too happy to hear - i think it’s important for you to understand that sentiment.

I’ve some personal, real-life, pains with ReScript:

  • Exception encoding is broken(most monitoring tool do not handle ReScript encoded exceptions)
  • Async/Await :frowning:
  • Dynamic imports is impossible, which is a major avenue for optimizations
  • Monorepo support is still broken(might not be part of the compiler, :man_shrugging: )
  • Sourcemaps are very much missing for any new dev we onboard

Yes please. we would love to discuss this - how can we make this happen?

8 Likes

I think it’s fine for @Hongbo to express that it’s demotivating to hear people in the community he’s been working to build for 7 years talk about switching to another option. And demotivated isn’t necessarily the same thing as unmotivated (he didn’t say he’d stop updates). It’s normal for humans go through waves of more or less motivation and it should be ok to express what causes that.

We all have to understand the context at the moment right now as well, parental leave isn’t quite a vacation and to still be checking in with the community at all right now is pretty awesome.

That said, it would be great if ReScript had a larger contributor team. If the community wants that future we should help shoulder the burden to find interested people.

7 Likes

Sorry to hear that, because that was not my intention. From my perspective it seems like it would take pressure off your back. You could point to it and say it reduces the risk of adopting ReScript because there are multiple options in this space and that you’re not the single person that everyone would need to depend on. Of course it would be ideal if everyone had the same vision, because you obviously did a fantastic job, but that’s the nature of open source, it attracts people who want to create their own vision.

I hope you change your mind about this, to me a fork is a sign of success, people think your work is so good that they want to use it to create their own vision.

19 Likes

Hi @Hongbo and team

This is a great discussion and it demonstrates that we have a community which genuinely cares about the success of the project.

Here are a few thoughts and questions:

Governance

What are your thoughts on introducing formal project governance, similar to what’s happening with Rust? Perhaps this was this the original intention behind the ReScript Association?

Core Team

Have some of the core team members retired from the project? That’s OK, and it’s an opportunity to bring new people into the core team. There are some sincerely dedicated community members that would be a great addition to the team. People who could contribute technically, but also people who can help coordinate events, marketing, etc.

Sponsors

It would be great to understand more clearly what no funding means. Does this mean that Meta no longer supports the project? I understand that Rust also does not have funding for core team members, but they do have sponsors for infrastructure.

Priorities

It’s important to discuss upcoming language features, but the technology is already in a good state, so it seems to me that the higher priority by far should be project management and governance. Revising the core team and delegating tasks to those members will help the project and free up @Hongbo’s time to dedicate time on research and technical guidance.

NPM Downloads

As a side note, it’s great to see that ReScript NPM downloads are heading in an upward trend.

33 Likes

@Hongbo you may consider something like the one Scala’s Play Framework did, the funding from it’s home company was cut, and they opened a Open Collective for companies using it to support development funding.

6 Likes

@kevanstannard that’s an amazing list.
thank you for putting this up!

Very curious to hear @Hongbo thoughts here, maybe we can start putting some of these efforts in place as a community or as a collection of organizations using ReScript.

Eventually, as a business using ReScript, my top-most concern is the continuity of the language.

7 Likes