4 ms·
I've been doing Clojure for the better part of 3 years now and I'm not sure I get why people feel doing web development in Clojure is hard. Our first foray in C
by akmiller 10y ago
I've been doing Clojure for the better part of 3 years now and I'm not sure I get why people feel doing web development in Clojure is hard. Our first foray in Clojure was/is an API to manage our users that was built by 2 developers who were new to the language and has been running largely unmodified since being released.
I actually believe the opposite. Jumping into and doing Clojure web development is extremely simple at the core. The issue with frameworks like Rails (and I'm not against Rails as I have used it on multiple successful projects and still think it's great) is that you get so much for free and don't have to understand how all the pieces fit and work together (at least initially). Soon enough you have to have more knowledge of that and that's were the complexity comes in.
- Bluestrike2 10y agoIs it fair to ding Rails for that, though? Regardless of what framework you're working with, eventually you're going to be peeking under the hood. Of either the framework, the language, or both. Whether that's front-loaded or not, it's still there. So the question becomes which framework eases you into the deep end of the pool, rather than which is the least complex. I've seen plenty of Rails apps that could have written better initially. But I haven't really seen any where it was impossible to refactor and improve them as a developer learns more.
- akmiller 10y agoI'm not dinging Rails for that. Like I said I've done some successful applications with Rails. The difference I'd say between Clojure is you learn those from the bottom up, whereas with Rails you learn from the top down. Either way, you are going to have to learn them!
- wyaeld 10y agoWhere exactly does it say that you can't start by actually learning how Rails works, before you build things with it? I think the biases of people who were experienced big system developers before they moved to Rails, are very different from those who started with it, potentially not understanding web app development very well, and then produced something challenging to maintain
- Bluestrike2 10y agoNo, I realize that. I was thinking more about complaints along those lines in general rather than anything you said specifically. Maybe it's just a case of setting unreasonable expectations as a consequence of how Rails in particular is recommended to newbies.
- s_kilk 10y ago> The issue with frameworks like Rails <... snip ...> is that you get so much for free and don't have to understand how all the pieces fit and work together Having used both Ruby/Rails and Clojure, I think Clojure swings too far in the opposite direction, where absolutely everything is foisted on the developer and they must hold the entire codebase in their head at once or drown. We even see this in luminus, the closest thing Clojure has to a web framework. It's just a leiningen template which spits files out on disk and says "there you go, it's your problem now". Of course there are upsides to this approach, but personally I've come to find developing web servers in Clojure a withering, joyless experience. Elixir and Phoenix show much more promise and seem to strike the right balance between featureful-ness and cleanliness.
- akmiller 10y ago> where absolutely everything is foisted on the developer and they must hold the entire codebase in their head at once or drown. I don't get that, and if that's how you feel I'd say you are doing functional programming wrong! That being said, I do agree about Luminous and I think it's a terrible way for a new web developer to Clojure to get started. Instead build your way up for what your app needs pulling in the libs as you need them and understanding how they fit and work together. Chances are you don't need that many at all.
- deleted 10y ago[deleted]