Live data from Hacker News

Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

book.fulcrologic.com

31–40 of 66 posts

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#31

Would anyone recommend Clojure if you run an engineering org and get to make decisions about languages? I've been running node shops for the last several years, and love Clojure since having hosted a couple meetups a while back. That and being most influenced by lispy/ai culture from SICP, CTM, PAIP, AIMA books. Node is getting tiresome due to not being able to trust the ecosystem quality (which takes away some of th…

Ladder (ladderlife.com) is written entirely Clojure(Script). We feel it was worth it - having a single language that can stretch from frontend to ETL code is pretty powerful. The fact that parallelism in Clojure is real (and not 16 separate processes) is pretty great too. Some of the downsides are: the slow startup time and fat(ish) JavaScript payloads because of the extra runtime libraries. The community can also be a bit unwelcoming of new ideas sometimes.

If you’re thinking of migrating - especially if it’s just a rest API - just start with Ring (& maybe bidi for routing). It’s not really a framework - you can pick and choose what else fits into your stack well after that. Clojure libraries tend to be very stateless and end up composing surprisingly well. I think Fulcro is a bit more useful if you’re building a frontend from scratch with React.

In terms of hiring - it’s very similar to a niche language. You get less folks that are specialists in Clojure like people are specialists in Node or Ruby. It’s also an easy to teach the language so you can bring most people up to speed in a month or so. Our hiring process favors generalists - and Clojure fits in well for that role. I don’t think specialists would have a good time with Clojure though - it’s not the kind of language that is easy to use as a means to an end.

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#32

Should I be using a Modern do-it-all frameworks for Clojure and Clojurescript? My opinion is of course colored by my years spent in JAVA/J2EE's world of web frameworks ( Wicket, Tapestry, JSF + Hibernate EJBs etc.). In this world, I found most of my time was spent in learning the deep intricacies of the framework and fitting it to my use case. I began to hate every minute I spent on these frameworks. And then I disco…

I’m a fan of using tools that fit your problem. I think Fulcro is probably better if you have a frontend that uses Fulcro/React. It can bring order to the sometimes Wild West of data fetching that happens in the browser world. That said - if your problem isn’t a full stack web app, don’t use Fulcro. Like you said, there is already very good tech for doing REST APIs or static html pages or the like. I don’t think Clojure has any frameworks like Ruby on Rails where you use it for all use cases. For example - I’d probably switch to httpkit over ring if I needed to solve a problem with async websockets.

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#33

Should I be using a Modern do-it-all frameworks for Clojure and Clojurescript? My opinion is of course colored by my years spent in JAVA/J2EE's world of web frameworks ( Wicket, Tapestry, JSF + Hibernate EJBs etc.). In this world, I found most of my time was spent in learning the deep intricacies of the framework and fitting it to my use case. I began to hate every minute I spent on these frameworks. And then I disco…

My understanding is that Fulcro is a frontend framework that also helps you build the communication between the browser and backend server: http://book.fulcrologic.com/#FullStack, http://book.fulcrologic.com/#_going_remote.

Of course, you can also use Fulcro to communicate with any sort of backend server, and still take advantage of Fulcro's normalized client-side database: http://book.fulcrologic.com/#Networking, http://book.fulcrologic.com/#_the_secret_sauce_normalizing_t...

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#34

Would anyone recommend Clojure if you run an engineering org and get to make decisions about languages? I've been running node shops for the last several years, and love Clojure since having hosted a couple meetups a while back. That and being most influenced by lispy/ai culture from SICP, CTM, PAIP, AIMA books. Node is getting tiresome due to not being able to trust the ecosystem quality (which takes away some of th…

In my experience -- I was a professional Clojure developer for 6 years (until 2018), and hung out in the #clojure IRC channel on freenode a lot between 2011 and 2014 -- the Clojure community tends to be very experienced. Clojure is not many people's first language, but tends to be a language you find your way to after dissatisfaction with other languages, or exposure to other lisps. I'm sure you can find crappy or ch…

You said 'was a professional Clojure developer'.

Are you not doing Clojure development anymore? If so, why?

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#35
post #11

Clojure is awesome. But refactoring a big project without a type system is very hard and error-prone, and clojure error messages are very difficult to understand.

Clojure has spec now, you can define and "force" your types there.

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#36

Would anyone recommend Clojure if you run an engineering org and get to make decisions about languages? I've been running node shops for the last several years, and love Clojure since having hosted a couple meetups a while back. That and being most influenced by lispy/ai culture from SICP, CTM, PAIP, AIMA books. Node is getting tiresome due to not being able to trust the ecosystem quality (which takes away some of th…

I work with Clojure about 50% of the time at my current job, and I can tell you that I've never felt blocked by it for anything. The libraries in Clojure are pretty ok, and when in doubt, I can virtually guarantee that a well-tested Java library exists for nearly anything you are working on.

In regards to dev-quality, I find that people that are interested in Clojure are typically good engineers, not due to the qualities of the language, but due more to its relatively niche-ness, attracting more enthusiasts.

I don't know anything about your stack, or Fulcro, but I've had no issue using Compojure for doing REST stuff.

EDIT: Just an FYI, I should point out that I work at a really big megacorporation, not a small startup or anything.

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#37

Does anyone have experience using Fulcro just for frontend (no backend)? I have been considering it versus Reagent and Rum for building a heavy client-side app that doesn't need a server (nothing to store in a database, local storage is fine). At some point I might add users for data sync between client and server but I don't plan to do SSR for SEO purposes at least. What I am curious about is if I use Fulcro, will I…

I think Fulcro would shine for your client-side state management use-case: http://book.fulcrologic.com/#_the_secret_sauce_normalizing_t...

Please also see the links from my reply elsewhere in this thread: https://news.ycombinator.com/item?id=19522998

I am exploring using Fulcro remotes to persist data locally using https://github.com/replikativ/datahike (and sync via https://github.com/replikativ/replikativ)

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#38

Really good work. I spent 15 minutes reading through this book over my first cup of coffee this morning. I stopped using Clojure about 5 years ago, after two long consulting jobs using Clojure. I decided Clojure was not a perfect fit for me (and, really, neither is Common Lisp, Racket, and Haskell - more favorite languages) but I am very happy to see the Clojure ecosystem still creating such great tools around the la…

Could you describe what the deficiencies or rough edges were with Clojure and Common Lisp in your experience with them?

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#39
post #11

Clojure is awesome. But refactoring a big project without a type system is very hard and error-prone, and clojure error messages are very difficult to understand.

This is true BUT data is easy to refactor and Clojure is really about Data. Clojure's big picture is a principled mental framework for reasoning about data, and as such gives us the core vocabulary and utilities we need to write programs that operate on data in a principled way (immutable data structures, immutable database etc).

So Clojure IMO is today in this awkward spot of saying "Here, use these new principles of data to go solve problems in this new better way!" but nobody has really deeply figured out what that even means. The whole middle ecosystem layer has yet to be written.

But it's happening, there's a movement of believers coordinated by Rich's talks and working to this common goal. And when it works, the whole 100k+ loc system that can't be changed will be but a memory.

(I am Hyperfiddle co-founder, Hyperfiddle poses the question: is it possible to express sophisticated database applications out of just data? We think we've made enough progress to show that the answer is probably yes. Hyperfiddle apps are not stored in git but rather in Datomic. And for special cases where you do need custom code, you can just drop down a layer seamlessly into Clojure.)

Re: Fulcro Developers Guide: Single-page full-stack web applications in clj/cljs

#40

Would anyone recommend Clojure if you run an engineering org and get to make decisions about languages? I've been running node shops for the last several years, and love Clojure since having hosted a couple meetups a while back. That and being most influenced by lispy/ai culture from SICP, CTM, PAIP, AIMA books. Node is getting tiresome due to not being able to trust the ecosystem quality (which takes away some of th…

The main issue with using Clojure is that you are expected to build everything out yourself. A lot of dependencies tend to stop being maintained after a while. Auth systems etc. are half-baked with 10 different implementations on GitHub. The newer shinier ones lack in features while the more featureful ones are from 3 years ago and have not seen a single update since. Now lisp people like to say "but...but.. backwards compatibility!" Sure that works for a lot of things but it goes out of the window when you need to prototype something quickly and your intern using Django/Rails has already built a MVP while you are still trying to sort out your dependencies story. Now you can always pull in Java libs, but then you will spend the rest of the week writing a wrapper for a very tiny subset of features that only you would use and the next person that comes along will have to do the same thing for the subset of features that they use.

Using Clojure (other Lisps have it way worse than Clojure so they are not even worth mentioning in an enterprise context) is a bit like using an extremely new cutting edge language like Rust or Nim where there's no high quality libraries for anything except the lowest common denominator but without the massive community and support. Yes Node has its issues. But at the end of the day, you still need to get things shipped. Elegant code that would look at home in SICP is useless when money is on the line and you can't ship. Clojure et al. is very much NOT a "Move Fast and Ship" type of language. If it's for a game jam where no one's using Unity and everyone's doing OpenGL or one of those dinky little Lua game dev suites, sure go for it. If it's your company, use Go and get things into production first.

Don't get me wrong, I love Clojure. There are a lot of smart people doing interesting things with it. It's probably the most advanced of all Lisps in terms of beginner-friendly tooling alone (shoutout to the Nightcode and Parinfer authors!) and it's Java interop is tremendously powerful in the right domain. Just that the ecosystem feels at times like Android 1.5 with its terrible fragmentation problems. The main corporate sponsor behind the language gives off apathetic vibes to community needs and the lack of featureful, maintained libraries is covered up under the guise of "Big frameworks bad! Elite programmers build their own!"

Post reply on HN