reasonml/reason-react

New ReScript and ReasonReact

aleksandrlat opened this issue · 5 comments

I could not find any useful info about ReasonReact in shadow of ReScript. So I'm asking here

Will ReasonReact be rebranded to ReScriptReact? Or something like this?
Can we use ReasonReact with ReScript?
Will ReasonReact be rewritten in ReScript?
Will the docs be updated to use ReScript?
Will new site appear for ReScriptReact?

If it is not right place to ask these questions could you please forward me to right place?

Watching. :)

Sharing some experience:

  • Will ReasonReact be rebranded to ReScriptReact? Or something like this?

See discussion

  • Can we use ReasonReact with ReScript?

Yes, here are some examples:

  1. rescript-project-template + reason-react (no specific bundler)
  2. Reason react starter (webpack based)
  3. app-template-reason-react: (shameless plug, snowpack based)
  • Will ReasonReact be rewritten in ReScript?

N/A

  • Will the docs be updated to use ReScript?

N/A

  • Will new site appear for ReScriptReact?

N/A

  • If it is not right place to ask these questions could you please forward me to right place?

I think ReScript Forum is a good place to start.

My $0.02 as someone who's brand new to ReScript and ReasonReact: updating the docs would be very much welcome. Ideally, the code examples should show three way comparisons between ReScript syntax, Reason syntax and JS output. I've managed to piece it all together but it's not at all obvious and directing folks to a forum is a good start but understandably a downer for newcomers.

woeps commented

To my knowledge @ryyppy is working on updating and improving the docs for reasonreact to be included in rescript-lang.org.

I'm not aware what is planned for the current site.

Thanks @woeps, let me provide some insights, because so far the whole ReScript migration process has been a pretty huge task. Please keep in mind that @rickyvetter might have different plans, I try to sync up with him once in a while to be sure our visions are aligned.

Can we use ReasonReact with ReScript?
Will ReasonReact be rewritten in ReScript?

Yes. The naming will most likely be simplified to rescript-react.
Still needs to be discussed within the team when & how the migration will be coordinated.

Generally, we think that it's better that we should call ReasonReact just ReScript / React, since the goal of these bindings is to be zero-cost, so it doesn't make much sense differentiating (especially in the module APIs). This will also be reflected in the new docs.

Will the docs be updated to use ReScript?
Will new site appear for ReScriptReact?

Yes, the new ReScript / React docs are already in a really good WIP shape on rescript-lang.org:
PR: rescript-association/rescript-lang.org#96
Preview:: https://rescript-langorg-de1emzdkk.vercel.app/docs/react/latest/introduction

The idea was to do a proper rewrite of all the important elements of React and put it into ReScript semantics.

There are still a few open questions on aligning doc writing / library evolution processes, because this change implies that code & docs are loosely coupled (requires tighter communication). React is an essential part of the ReScript toolchain though, so it makes more sense to keep everything on one site.

Please note: While I was working on this, the React project announced a rewrite to a hooks-only doc version as well, so I am pretty curious on what concepts they are going to promote, so I can align that results with our docs as well.