3 ms·
> You still have to know javascript Yes, you have to be familiar with the underlying platform. This is also true for languages running on top of the JVM, as yo
by bad_user 11y ago
> You still have to know javascript
Yes, you have to be familiar with the underlying platform. This is also true for languages running on top of the JVM, as you have to be familiar with the JVM and Java's ecosystem and with POSIX and with the target operating system and so on. And that's not just for Scala and the JVM. Don't get me wrong, you don't have to be an expert, but some knowledge of your underlying stack is always required.
> Having a problem with the scala version of the react library you want to use? Write up a question for stack overflow, post an issue on github, and then hunker down in the source code and try to find the answer on your own while waiting a few days for a response.
Isn't that, you know, how programming works? Yes, you end up interacting with other people through GitHub Issues, Gitter/IRC channels, StackOverflow, etc. It's actually rewarding, because you end up learning a lot. Us developers, we tend to be introverts. It's hurting us ;-)
> The compilation down to ES6 is so trivial that I don't have to try to guess what the compiler is doing.
It also means that Typescript is barely a step up from Javascript, so why bother? If you're going to be hip and choose an option that isn't THE mainstream choice, don't you want to pick something that brings enough benefits, to counter-balance the disadvantages of not going for straight Javascript?
Scala is a statically typed language in a way that Typescript will never be. Scala enables functional programming in a way that Typescript will never do. For all the bitching and moaning about Scala's SBT build tool and Maven's repositories, it's light years beyond the clusterfuck in Javascript's land when it comes to build tools, continuous integration and dependencies management.
And the best part of Scala.js is that you get to use many Scala libraries that are now cross-compiled. That means for example many of the Typelevel libraries, like Simulacrum, Cats, Shapeless, Spire and as a shameless plug, my own Monix: https://github.com/monixio/monix/ https://github.com/monixio/monix/
Scala's ecosystem isn't huge, like that of Java or Javascript, but you know, libraries tend to be in much better shape. For example Scala always had good Future implementations (again, versus the clusterfuck that happened in Javascript) and now Scala has Scala-Async which gives you async/await keywords without having to sacrifice browser compatibility: https://github.com/scala/async https://github.com/scala/async
Have a problem with React? Fix it. That's how you and the community can grow.
- spriggan3 11y ago> Have a problem with React? Fix it. That's not how things work in the real world and you know it. Furthermore if you're good enough to fix React then you're good enough to write a complicated JS codebase without the need for a third party language. > It also means that Typescript is barely a step up from Javascript Typescript is a huge step up from Javascript has it brings type safety, which eliminates a whole class of errors, make the code easier to read and document and the price to pay for using TS is quite low compared to using Scala.js . Scala has its place, but right now it's definitely not in the front-end.