4 ms·
I've been writing side projects in clojure for over a year now, and really enjoyed this assessment/review. The line, "At those moments, you're basically program
by claytn 6y ago
I've been writing side projects in clojure for over a year now, and really enjoyed this assessment/review. The line, "At those moments, you're basically programming Java with parentheses" hit home for me. I'll always brag about the interop capabilities of clojure, but I will avoid using it as much as possible.
- elwell 6y agoAnecdotally, I've been using Clojure professionally for about seven years and only very rarely need to interop with Java. Of course it depends on what you're trying to accomplish. On the other hand, interop with JS from ClojureScript is very common; shadow-cljs has made that experience more inviting.
- cutler 6y agoMy experience with Clojurescript has been the opposite. React, on which most idiomatic CLJS is based (Om, Reagent), is such a moving target that Clojurescript is now years behind the curve. There was a lot of initial momentum under David Nolen's stewardship but that seems to have faded. React now has hooks and form but Reagent is basically the same as when it first appeared.
- diggan 6y agoI keep seeing this line of reasoning that ClojureScript/Reagent somehow slipped behind React because of "hooks" and "form" (form is a new complaint actually, haven't heard before), but I'm failing to understand what hooks could give us in Reagent-land that we don't already have? With that said, you can still use React hooks via Reagent if you want to, it's described over here: https://github.com/reagent-project/reagent/blob/master/doc/ReactFeatures.md#hooks https://github.com/reagent-project/reagent/blob/master/doc/R...
- dkersten 6y agoAren't hooks default in reagent now? Or at least, wasn't there a move in that direction a few months back? Personally, I use reagent (with re-frame) and the only times I need to do JS interop is when using JS libraries (which shadow-cljs has made easy -- I know that Clojurescript has better support now too, but I've not used it because I was already a shadow-cljs user).
- deleted 6y ago[deleted]
- dkersten 6y agoI'm also a longtime Clojure user and I barely use Java interop at all. Occasionally I do something like convert an instant to a java.sql.Timestamp, or I call Math/abs or something, but even these tend to be isolated cases. Its rare that I need deeper interop, unless I'm wrapping a Java library myself (which I haven't needed to do in a long time). The biggest area where the JVM leaks through is exceptions and error messages.