5 ms·
This looks pretty interesting. It makes me want to learn OCaml. :-P I've been using Coffeescript in projects for about two years. I know people have raised iss
by djsumdog 10y ago
This looks pretty interesting. It makes me want to learn OCaml. :-P
I've been using Coffeescript in projects for about two years. I know people have raised issues with it vs ES6, but I still really like Coffeescript. I feels more natural with my Scala/Ruby background and it outputs into Javascript in ways that (mostly) make sense and are predictable.
- aikah 10y ago> This looks pretty interesting. It makes me want to learn OCaml. :-P You can learn F# with dotnet core, which has a better ecosystem for web development. OCaml is quite poor in that domain.
- KurtMueller 10y agoAre you speaking from experience? If so, do you have any or know of any resources I could look at? Also, what type of backend are you using with F# and dotnet core?
- ZenoArrow 10y agoIf you want the BuckleScript equivalent for F#, that would be Fable. https://github.com/fable-compiler/Fable/blob/master/README.md https://github.com/fable-compiler/Fable/blob/master/README.m... There's a newer branch called Fable Arch which I believe is focused on promoting the Elm Architecture for structuring web apps: https://github.com/fable-compiler/fable-arch https://github.com/fable-compiler/fable-arch FunScript is another alternative: http://funscript.info/ http://funscript.info/
- Paradigma11 10y agoI do not think that Arch is a newer branch but a framework that uses the standard fable compiler.
- elbear 10y agoElm Architecture for F# is Elmish: https://github.com/fable-compiler/fable-elmish https://github.com/fable-compiler/fable-elmish
- Paradigma11 10y agoOne popular web server is https://suave.io/ https://suave.io/ You can use http://fable.io/ http://fable.io/ for f# -> js transpilation. One big advantage is that you are able to use ts definitions for foreign js libraries. The js is generated by babel which is also nice. There are several active projects and bindings that you can take a look at there: https://github.com/fable-compiler https://github.com/fable-compiler
- KurtMueller 10y agoWhat kind of data store do you use with F#? Some sort of SQL variant?
- Paradigma11 10y agohttps://blog.geist.no/suave-io-introduction-and-example-part-4-database-access/ https://blog.geist.no/suave-io-introduction-and-example-part... "Database access from a Suave.IO app isn't any different from database access from any other .NET / F# app you write." Any way you like, really.
- yawaramin 10y agoHave you heard of Ocsigen/Eliom? It's a complete OCaml system for web development.
- partycoder 10y agoWhile CoffeeScript has some useful additions, it also has some that were not good ideas. When the language helps communicating an idea more clearly and concisely, it's fine. But removing delimiters in my opinion does not help readability. Most time is spent reading, not writing. It's similar to claiming more efficiency by removing lanes and signaling from a highway... Then, whitespace has more meaning than it should in CoffeeScript, and inconsistent indentation is possible, whereas in Python/Ruby it is not without an error. Therefore a formatter can break your code. Snippets/templates/autocompletion can save the work of typing delimiters. Delimiters can be enforced with CoffeeLint, but then that's optional, it is more work, and it is a friction point with people that do not see value in formatting. CoffeeScript does not have a lot of tooling around it, and the community has moved on. There are documentation tools like docco and codo, but there is no tooling that makes it as well integrated with the language as JavaScript + JSDoc, where there is tooling that can verify types, function parameters and return types giving you a lot of static analysis power. Then, the entire point of a scripting language is not having to compile. With CoffeeScript you lose that advantage to some extent, and the compiler does not filter many errors, making it a bad tradeoff.
- k__ 10y agoI was using LiveScript before ES2015 and syntax-wise it felt a step backwards to go back to JavaScript.