6 ms·
Clojure Web Development Evolved [video]
- ilrwbwrkhv 4y agoI really wanted to use Clojure but even with this modern tooling it feels a bit "Java"-ish.
- valbaca 4y agoYou might be more interested in this video: https://www.youtube.com/watch?v=3HxVMGaiZbc https://www.youtube.com/watch?v=3HxVMGaiZbc "ClojureScript in the Age of TypeScript — David Nolen" Skip to 30:00 for the live coding demo: https://youtu.be/3HxVMGaiZbc?t=1800 https://youtu.be/3HxVMGaiZbc?t=1800
- ilrwbwrkhv 4y agoOk this is excellent stuff.
- inferiorhuman 4y agoMeh. ClojureScript is just as leaky as Clojure. Clojure brings all the XML pain of Java dependencies and slow start times, ClojureScript gets callback hell. They're fantastic languages but I couldn't help but wonder if there were a better VM to base them on.
- robertfw 4y agoWhat XML pain are you referring to? It's not something I've had to deal with in ~3-4 years of professional Clojure work The slow start times are meaningless for long lived servers, which Clojure is best suited for. For fast startup time there is now Babashka which is great for many tasks, and GraalVM as another option.
- heretoo 4y ago> ClojureScript is just as leaky as Clojure By leaky, I assume you are refering to the interop with the host platform. Overall, this seems like a benefit, simply for having access to many more libraries than would otherwise exist in Clojure(script). > Clojure brings all the XML pain of Java dependencies Do you mean pom.xml? > better VM The JVM seems extremely powerful with regards to performance and memory management, with 20+ years of backwards compatibility (mostly), and improvements still being made with GC and JIT.
- kaba0 4y agoWhere the hell do you see XML in java development anymore, let alone in Clojure?
- dekelpilli 4y agoPresumably in Maven POM files for Java
- jgalt212 4y agoand React brings all the XML pain into HTML templates.
- yogthos 4y agoAnd Reagent removes all that pain in ClojureScript https://reagent-project.github.io/ https://reagent-project.github.io/
- jffry 4y ago> Clojure brings all the XML pain of Java dependencies You don't have to use pom.xml for Clojure projects. The default, included-with-the-clojure-cli support to define your dependencies in deps.edn makes dependency management extremely simple ;deps.edn {:deps {org.postgresql/postgresql {:mvn/version "42.4.0"}}}
- deleted 4y ago[deleted]
- deleted 4y ago[deleted]
- nico 4y agoSkip to minute 25 if you want to see the demo first.
- hellohowareu 4y agoI like programming in Clojure. My brain flowed pretty easily in it-- it felt very much like opening and collapsing computations-- in a natural way, like algebra. I just don't like its enigmatic stack traces when an error occured-- it was difficult to understand the how/why/where of errors. I did not like its relation to with Java. Nor the Java tooling. And ReAgent isn't exactly foolproof. ReAgent felt... buggy, and certainly not as easy to use as I felt ReactJS is. (ReAgent compiles to ReactJS) Then again, it has been about 3 years, maybe I'll try it again sometime. Or at least another functional programming focused language. I liked Clojure, but I was happy to return to NodeJS & ReactJS-- the latter being in higher demand, and felt easier to work with in terms of stack tracing, build system, and debugging. But yeah, as a language, Clojure itself is nice to work with.
- dimitar 4y agoThis is a great article on the errors: https://lambdaisland.com/blog/2022-04-07-Clojure-Error-Messages https://lambdaisland.com/blog/2022-04-07-Clojure-Error-Messa... Also the REPL makes it so easy to debugging: https://www.cognitect.com/blog/2017/6/5/repl-debugging-no-stacktrace-required https://www.cognitect.com/blog/2017/6/5/repl-debugging-no-st...
- janetacarr 4y agoAnother attempt at the Rails for Clojure. Great. The web stacks (yes stacks, there are many at this point) are very mature. I'm getting tired of seeing people re-inventing the wheel over and over again. I love Clojure, but this language is going to die off if people don't start putting more effort into building mundane, everyday libraries. (I know I am). Clojure has high velocity, but it's always offset by having to create new libraries or update rotting ones. I've noticed a ton of software rot in what were once major Clojure libraries, like Onyx and Cortex, now fading into obsolescence. I'm sorry, but I will keep bitching about this on HN until people help me.
- hewrin10 4y agoWhat kind of mundane libraries don't exist? And do you mind sharing what you are working on?
- Barrin92 4y agonot the OP but this struck home for me because I just recently worked with Clojure and I was surprised that there was no standard library to deal with filepath operations. Having to use Java's nio, immediately exposed some weirdnesses, like having to pass an empty array to Paths.get() because just calling it with a string with one parameter made it chose the wrong overloaded function.
- jhhh 4y agoVararg support in interop and type creation (deftype/defprotocol) seems like a reasonable ask.
- lenkite 4y agohttps://babashka.org/fs/codox/babashka.fs.html#var-path https://babashka.org/fs/codox/babashka.fs.html#var-path
- didibus 4y agoYou can type hint to pick the one of the type you're looking for. It's not any weirder than in Java, no need to pass an empty array.
- lbj 4y agoClojure's webstack has actually made webdevelopment interesting again. Most of the other "innovations" in webdev has added tons of complexity without benefits that match.
- adham-omran 4y agoI have been taking a look at Clojure for the past couple of weeks. Although I'm not a fan of web development as is in JavaScript, Clojure looks more inviting to me.
- Lchdgvhkh 4y ago