3 ms·
I’m not a fan of TypeScript, and never heard of Reason, but this post makes me like TypeScript more. I prefer the fact it’s more explicit and less magic. The e
by philliphaydon 7y ago
I’m not a fan of TypeScript, and never heard of Reason, but this post makes me like TypeScript more. I prefer the fact it’s more explicit and less magic.
The examples in TS are very easy to understand where Reason just looks like magic and I have to think more about what it might be doing. I don’t see a benefit to Reason over vanilla JS.
/opinion
- wry_discontent 7y agoThat basically amounts to "I have learned Typescript and not Reason, therefore Typescript is better." I'm not a Reason pro, but it doesn't look magical to me. It seems just as explicit, and actually more so in the reducer example.
- Rapzid 7y agoF# tackles this disconnect between working on the code in an IDE and reading code with an interesting documentation system: https://fsprojects.github.io/FSharp.Formatting/metadata.html https://fsprojects.github.io/FSharp.Formatting/metadata.html . Mouse over the code :)
- devmunchies 7y agoi hate those tooltips when they get in my way. I wish they only showed up if you hold control + hover or something like that.
- eptcyka 7y agoI'd argue that's because ReasonML/Buckle is a completely different language whereas Typescript is a superset of JavaScript. I don't believe that one is inherently more legible than the other, but you might have trouble reading Reason if all you know is C-style languages.
- crimsonalucard 7y agoYou need to study ML based languages like Haskell and reason to see why reason is actually more explicit then type script. It takes some effort but in the end you'll have a better understanding of programming in general. Typescript is missing the Variant type primitive so it has to be written in a roundabout way to imitate that primitive (and it most likely isn't type checked correctly either). The extra code you are writing in TS is not explicit... a better term is obfuscates.