5 ms·
Well you don't have much choice for frontend for one. Typescript offers much stronger typing than Ruby, Python, Clojure and PHP as well.
by seanwilson 10y ago
Well you don't have much choice for frontend for one. Typescript offers much stronger typing than Ruby, Python, Clojure and PHP as well.
- winter_blue 10y agoIf I were to start a new project today, I would use Elm[1] for the front-end. It's a very well-designed language (reminiscent of Haskell), specifically designed with HTML and DOM manipulation in mind. [1] http://elm-lang.org/ http://elm-lang.org/
- chriswwweb 10y agoIs using elm really worth it? I have not yet tried elm, but I wonder if it's advantages really justify the increased costs that this choice might bring? Isn't elm a little bit too young? I mean is the time you and your coworkers will need to learn it, the increased difficulty to hire skilled elm developers, the increased difficulty to find good training courses for new junior developers you hire, the increased difficulty to debug the code compared to js, the lack of third party libraries ... really worth it?
- winter_blue 10y ago> the increased difficulty to debug the code compared to js Elm has an amazing time-traveling debugging system: http://debug.elm-lang.org/ http://debug.elm-lang.org/ This is a cut above pretty much every other front-end JS framework, and languages that transpile to JS. > the lack of third party libraries It has JavaScript interop that's based around message-passing. The JS library is treated sort of like a service, and thus the Elm code is kept isolated from it: https://guide.elm-lang.org/interop/javascript.html https://guide.elm-lang.org/interop/javascript.html > the increased difficulty to find good training courses for new junior developers you hire The official docs are pretty good. A good programmer shouldn't have a trouble picking it up. The architectural benefits of using Elm (that lead to a high-quality, almost zero bugs website) is IMO worth it.
- leshow 10y agoIMO actually decreases costs because of the amount of errors the type system catches and the ease of refactoring. Elm also guarentees to NOT produce ANY runtime errors, that's quite a guarantee.
- seanwilson 10y agoSounds interesting and I'd love to code in a real functional language instead of functional style in an imperative language. I haven't looked into Elm but isn't this going against the grain too much? TypeScript seems to be gaining traction such as with Angular 2. I mean I could code in OCaml with a transpiler to JavaScript if I wanted to but it probably isn't worth the friction.
- Wintamute 10y agoSurely by using Elm you may improve the quality of your program, but you restrict your staffing choices down to the <1% of frontenders who either know it already, or are capable of quickly picking up a Haskell-esque language. Either that or you commit your client to huge up-front training costs. Or how about the scenario that goes like: "The contractor who wrote our web app in Elm left last month, but we need some bug fixes or complex feature adding. Can someone fix it? Anybody? No?" How do you sell that to a client?
- pjmlp 10y agoFor me frontend == native, so I have plenty of choices.
- edem 10y agoStronger typing than clojure? You gotta check out clojure.spec which is built into the language itself.
- seanwilson 10y agoAh, I'm not that familiar with Clojure. Is that commonly used? Are there any good examples of complex properties you can capture with its type system?
- edem 10y agoSee for yourself, Stuart Halloway (clojure committer) can explain it much better than me: https://www.youtube.com/watch?v=VNTQ-M_uSo8 https://www.youtube.com/watch?v=VNTQ-M_uSo8
- edem 10y agoYou have actually. For example ClojureScript compiles to JS.