Live data from Hacker News

Reason React 0.8

github.com

51–60 of 85 posts

Re: Reason React 0.8

#51
post #17

Earlier quoted context omitted.

The approach I've been taking is to use ReasonML to model the domain of my application as well as high level components. ReasonML code remains unaware of the styling of the "lower-level" components for the most part, which I write in typescript with styled-components or emotion.

Is there any reason to prefer styled-components over emotion? I did a deep dive on this a few months ago, and found that Emotion supports the same API as SC, while also offering benefits like the `sx` prop, not to mention SSR for "free". It also had a reputation for being faster, but I didn't bother to benchmark it.

I'm bias as a contributor but Emotion does offer those perks "for free". Emotion has had a track record of quality engineering - Kye pioneered the babel plugin idea in its early days.

Re: Reason React 0.8

#52

The long awaited 0.8.0 release from Reason React is out of beta! This includes a lot of the niceties of writing React but in a very fast, type safe language. If this is your first time hearing about Reason, watch a video from its creator (Jordan Walke, creator of React) to learn more: https://www.youtube.com/watch?v=5fG_lyNuEAw&t=11s Fun facts about Reason: - exports TypeScript! If you have a TS project and looking f…

If the language has proved to be worthy, why messenger.com only though?

Re: Reason React 0.8

#53
post #46

Earlier quoted context omitted.

Hi, the author of BuckleScript here. JSOO and BuckleScript has very different goals, the former focuses on the compatibility with native, while the latter focuses on the interop and optimal perf on JS backend. The progress of BuckleScript is actually much faster this year if you follow the development closely. OCaml as a language which has been developed for more than 20 years is quite usable without using the latest…

Please, you're driving me crazy. I have referred to you personally by name in two of my above comments. I know who you are! I also know about JSOO vs BS! I know! And it's super disorienting when every single prominent person from the Reason/BuckleScript ecosystem arrives in this thread just to reply directly to my comments with a canned message that has little to do with my original points. Yes, OCaml is older! Yes,…

I'm an outsider but it appears to me that he's addressing your points. You are specifically comparing JSOO to BS and seem to be asking how can BS keep up? You got a response that they are two projects with two different goals, and hence they can't really be compared in the way you are comparing them.

I'm not sure what's driving you crazy about this interaction.

Re: Reason React 0.8

#54
post #34

Earlier quoted context omitted.

> TypeScript's inherent JS-like nature can pop up subtle bugs like forgetting to type a pair of parentheses FWIW this was just fixed in TypeScript 3.9.

Interesting, can you link me? EDIT: I just tried in the TypeScript Playground (v3.9.2), it's actually rather worse than I thought, it prints not 'false' but the actual function itself as a value...

https://devblogs.microsoft.com/typescript/announcing-typescr...

Edit: Apparently the functionality already exists as of 3.7. The update in 3.9 was to add it to ternary operations as well

Re: Reason React 0.8

#55

The long awaited 0.8.0 release from Reason React is out of beta! This includes a lot of the niceties of writing React but in a very fast, type safe language. If this is your first time hearing about Reason, watch a video from its creator (Jordan Walke, creator of React) to learn more: https://www.youtube.com/watch?v=5fG_lyNuEAw&t=11s Fun facts about Reason: - exports TypeScript! If you have a TS project and looking f…

Congratulations! I hope Reason and Reason React could get more tractions.

I'm wondering, will there be more marketing for Reason or Reason React after it reaching 1.0?

I found when introducing this kind of technology for day jobs, people either get confused or concerned usually, even though it really looks like React now.

It seems to be very hard to have programming languages taking off without marketing nowadays because the adoption usually comes from other people's adoption. It's the "threshold of immortality" of programming languages according to Simon Peyton Jones.

Re: Reason React 0.8

#56
post #15
post #12

Earlier quoted context omitted.

As far as editor support, I have used reason-language-server ( https://github.com/jaredly/reason-language-server ) with Emacs (current), Vim and VSCode (provided through reason-vscode plugin). I used to use IntelliJ, and there was a solid plugin for that as well. ReasonML's compiler is way faster than Typescript's.

There's a difference between "the compiler is faster when run at the CLI" and "the language server is faster". A good language server remains responsive by doing quick, partial compilations on just the section that changed. A bad language server just wraps the standard compiler and re-runs the whole thing when a file is saved. The latter will eat up CPU/RAM and make for a frustrating dev experience, no matter how rel…

The standard compiler can do a cold compile of a single file in milliseconds. When the compiler is that fast you _can_ just wrap it up and it'll still be faster than TypeScript.

But to answer your actual question: The current standard (reason-language-server) does simply wrap the compiler, and it's more than fast enough, but the community is working on a new merlin-based language server (ocaml-lsp) which does support partial compilation.

Re: Reason React 0.8

#57

The long awaited 0.8.0 release from Reason React is out of beta! This includes a lot of the niceties of writing React but in a very fast, type safe language. If this is your first time hearing about Reason, watch a video from its creator (Jordan Walke, creator of React) to learn more: https://www.youtube.com/watch?v=5fG_lyNuEAw&t=11s Fun facts about Reason: - exports TypeScript! If you have a TS project and looking f…

If the language has proved to be worthy, why messenger.com only though?

This meritocratic model is unfortunately not really how language popularity plays out in the real world. At least not on career-length timescales.

Re: Reason React 0.8

#58

For me a big strength is Reason's intolerance of null, this has eliminated a great number of bugs for me. Reason React ultimately forces you to think about every permutation of state your component might enter, and develop logic to handle that. JS/TS will never help you with that.

What do you mean? Typescript by default assumes non-null, and if you specify that something can be null it'll force you to check that it isn't before attempting to access it.

Re: Reason React 0.8

#59
post #57

Earlier quoted context omitted.

If the language has proved to be worthy, why messenger.com only though?

This meritocratic model is unfortunately not really how language popularity plays out in the real world. At least not on career-length timescales.

Was referring to Facebook usage only, like in, why isn't it used more at FB?

Re: Reason React 0.8

#60

Hey there, is there a `styled-components` library for Reason? I'm really considering ReasonML for my app, however I'm not a big fan of the styling in reason react.

Hey, I recommend sticking to bs-css (https://github.com/reasonml-labs/bs-css). Not because I don't think styled-ppx is super cool or amazing, but because it's so cutting edge your 99% chance going to run into an edge case that isn't well accounted for yet (I had a number of issues when I tried it). bs-css is battle tested today, so if you're goal is stability, I recommend it first.
Post reply on HN