DEV Community

Discussion on: My Four Year Quest For Perfect Scala.js UI Development

Collapse
 
raquo profile image
Nikita Gazarov

I like Scala's combination of those approaches very much. It's a sharp sword but if you know to avoid pitfalls like ten layer class hierarchies, the FP + OOP integration works very well. It's also why it's so controversial: Scala is very non-prescriptive, it's on you to make good decisions.

I find pure Haskell-style FP too constraining, and the overhead of typed effects very unnecessary on the frontend – UI applications are essentially nothing but bunches of DOM manipulation effects, and the parts that don't need to touch the DOM have very little risk of doing so even without types to enforce it, so wrapping everything in effect types is just pointless IMO.

I haven't coded in ReasonML but yes, it's just a more approachable syntax for OCaml. Should be a good FP focused alternative.