Fork me on GitHub
#off-topic
<
2018-10-10
>
alexpashkov13:10:09

Should I pick clojurescript or elm?

mpenet13:10:06

Asking this here is risky 🙂

alexpashkov13:10:10

I do boxing 😄

dpsutton13:10:52

do you like types or lisp? also, what are your external needs. clojurescript likely works with external libs better than elm

spinningtopsofdoom13:10:23

Elm types, friendlier errors, maybe easier ramp up(? ) ClojureScript data structures, whole program optimization, code splitting

spinningtopsofdoom13:10:19

That's off the top of my head for strengths of each platform.

vemv13:10:19

I'd compare cljs against Reason instead, seems to have more support / life expectancy (see https://news.ycombinator.com/item?id=16510723 . Might be random opinions from the internet though)

gklijs14:10:07

@alexpashkov123 If you don’t like websockets and you do like breaking updates ELM, if you like runtime exceptions, and easy javascript interop Clojurescript

gklijs14:10:59

Elm also has code splitting with the new version

mpenet14:10:42

is elm still a one man show (mostly)?

danielstockton14:10:55

Cljs is also a one man show (mostly)?

bronsa14:10:37

it's been at least a 2-men show for a while now

🚀 4
dpsutton14:10:25

is this for work or for learning?

dpsutton14:10:00

for fun/hobby just pick the style you like better: ML or lisp. if for work figure out what "trick" would help your project the most and which ecosystem supports it best

mpenet14:10:44

Swannodette cannot be just one person, there must be an army of devs behind that account

☝️ 20
danm14:10:19

You're probably right, but why would you work like that...?

mpenet14:10:30

Reason does seem to have some traction. It's a nice language

mpenet14:10:13

You can get away with using ocaml+bucklescript if you prefer ml style syntax more, reason seems to based largely on these 2

emccue16:10:33

It really depends on your task

emccue16:10:03

I think @dpsutton's phrasing is best

emccue16:10:13

do you need types or lisp?

emccue16:10:13

we have spec for some runtime validation but in general if you pick clojure you are picking it for the dynamism

emccue16:10:22

thats the killer feature

emccue16:10:57

Elm is really really good for what it is

emccue16:10:34

which is a statically typed language

emccue16:10:31

If you think the benefits of static languages (no runtime errors, etc.) outweigh the downsides (repetitively declaring data structure, tight coupling to types) then Elm is the best

emccue16:10:47

(for your project)

emccue16:10:23

If you think the benefits of dynamic languages (rapid experimentation, loose coupling) outwiegh the downsides (runtime errors) then go for clojure

emccue16:10:48

(for your project)

Conor16:10:37

Church types vs. Curry types

emccue16:10:08

If you think the benefits of javascript (popularity) outweigh the downsides (( ZA̡͊͠͝LGΌ ISͮ̂҉̯͈͕̹̘̱ TO͇̹̺ͅƝ̴ȳ̳ TH̘Ë͖́̉ ͠P̯͍̭O̚​N̐Y̡ H̸̡̪̯ͨ͊̽̅̾̎Ȩ̬̩̾͛ͪ̈́̀́͘ ̶̧̨̱̹̭̯ͧ̾ͬC̷̙̲̝͖ͭ̏ͥͮ͟Oͮ͏̮̪̝͍M̲̖͊̒ͪͩͬ̚̚͜Ȇ̴̟̟͙̞ͩ͌͝S̨̥̫͎̭ͯ̿̔̀ͅ) )

emccue16:10:13

well, godspeed

😂 8
☝️ 4
andy.fingerhut16:10:56

Has anyone written the book "Javascript: The Lovecraftian Parts" yet/

👍 4
mauricio.szabo16:10:37

The problem with any "new" language is probably the ability to make things fast. You probably want to engineer a beautiful solution, but sometime you'll have to do something FAST or do experiments. Elm is probably not good for that (you can't cheat, you need to match types and wrap interop correctly)

emccue16:10:11

Less abstractly talking, I did some experiments with Elm at my last coop

emccue16:10:29

It is very good for making idiots (me) build well architected applications. The Elm architecture is very nice and the fact that the language drives you so heavily toward it is super beneficial

tbaldridge16:10:54

@mauricio.szabo that's true. I've written more Lisp interpreters than I can count, and can write one in about an hour in Clojure/C#/Python. I've been spending most of my free time for a week now writing one in F#. 😄

tbaldridge16:10:33

Especially with statically typed languages it's really tempting to make the code elegant so sometimes I waste hours figuring out how to code golf some function.

emccue16:10:11

One place where you will lose out in elm is reusable components

emccue16:10:28

you cant really cheat and give a navbar a bit of internal state

emccue16:10:17

For an extreme example of what a reusable component can end up looking like take a gander at elm-autocomplete

emccue16:10:23

It even sounds dumb to me saying it now, but losing out on the React ecosystem really hurts too

emccue16:10:52

just being able to do [:> SomeThirdPartyReactComponent] in reagent is nice (when/if you get npm to play nice with the google closure compiler. I heard shadow-cljs helps this alot)

emccue16:10:48

You can always take the little taco lady approach and try out both though