3 ms·
Clojure is nice for heavy data engineering projects that require robust/stable/mature tech like the JVM. But for a full stack language for a web app it just add
by Scarbutt 6y ago
Clojure is nice for heavy data engineering projects that require robust/stable/mature tech like the JVM. But for a full stack language for a web app it just adds a tons of complexity over just using JS.
In Clojurescript interacting with the JS ecosystem is painful cause of its reliance on the closure compiler.
In Clojure, is almost the same, most Java libs are over-engineered and horrible to use but you need to reach for them because Clojure lacks an ecosystem.
So while Clojure is a better/nicer language than JS, the tradeoffs are not worth it if you want only one language for your webapp (SPA and server).
- danenania 6y agoIt’s been years since I used clojurescript so ymmv, but imo integrating so tightly with the closure compiler was a big mistake. It adds tons of futziness and build complexity for what, in practice, are usually pretty marginal reductions in bundle size that end users won’t notice.
- nickbauman 6y agoNever had a problem with the closure compiler vis-a-vis ClojureScript, is this really a thing?
- StreamBright 6y agoIt is a valid point I don't know why the downvotes. I think Rich had to make a decision, writing a completely new LISP from scratch or leverage an ecosystem and create a LISP on the top. >> In Clojure, is almost the same, most Java libs are over-engineered and horrible to use but you need to reach for them because Clojure lacks an ecosystem. The biggest problem with Java libs the mixed quality. Many big data project have this problem, if you peek under the hood you gonna be amazed about abstractions leaking into different bits and pieces of the system. My favourite example how ORC imports Hadoop FS https://github.com/apache/orc/blob/master/java/core/src/java/org/apache/orc/OrcFile.java#L31 https://github.com/apache/orc/blob/master/java/core/src/java... There is one more problem with Clojure that I find annoying, the actual Java interop. I was running into issues with this many times and some Jave libs are almost unusable without a thin wrapper written in pure Java. Other than that, I think Clojure is still one of the best options out there.
- pjmlp 6y agoWhat you see as negatives, I see as Clojure's main selling points. I usually avoid languages that keep reinventing the wheel of established libraries on the platform, "'cause it isn't idiomatic".
- Scarbutt 6y agoDon't disagree with you but two things: 1. Clojure doesn't have as good interop as Kotlin. 2. For some heavy interop projects, it's simpler to write the thing Java.
- pjmlp 6y agoWhat good interop does Kotlin have better than Clojure in what concerns calling Java code? And on the other direction is just as fun, try to call Kotlin co-routines from Java without having to write wrappers for it, or Kotlin code without putting @Jvm... annotations everywhere.
- rlander 6y ago> adds a tons of complexity over just using JS. What "tons complexity" are you talking about? Clojure is a much simpler language (in the decomplected sense) than JS. Less syntax, better build tools, uniform stdlib, no webpack/babel nonsense. This sentence makes no sense. > interacting with the JS ecosystem is painful cause of its reliance on the closure compiler. Again, what? With tools like shadow-cljs, requiring JS libs and using them in you project is trivial (just require and import like you would any cljs library). > In Clojure, is almost the same, most Java libs are over-engineered and horrible to use but you need to reach for them because Clojure lacks an ecosystem. I've been writing Clojure for 10 years and rarely have I had to reach for Java. This is absolute rubbish. You seem to hold strong opinions about a language you barely understand. Edit: reading you comment history, you seem to have an axe to grind with Clojure.