Arguments for Clojurescript vs Angular 2/4

Arguments for Clojurescript vs Angular 2/4

Hopefully this kind of question is acceptable here.

nonessential So we are in the process of sorting out the spaghetti jquery code base that is our current frontend. I have been researching options for quite a while now, from es6 React to ghcjs haskell Reflex and Purescript. I ended up quite confidently settling for Clojurescript over Javascript due to the (IMO) better thought out language design, and over the others due to their relative obscurity. Not that I would throw out Clojurescript if Purescript or Ghcjs were more prominent, but they would be strong contenders alongside it. I also considered Elm, but I think its lack of typeclasses is problematic because they are, in my opinion, the very thing that allow Haskell to be so strict in its typing and yet still remain incredibly expressive. nonessential

Anyway, now there's some significant pressure to adopt Angular 2/4 and TypeScript instead of Clojurescript. Obviously I have to remain open to the possibility that it is indeed preferable, but I think arguments for Angular will be provided in abundance without my help, so it makes more sense for me to focus more on gathering arguments in favor of Clojurescript.

I know that two aren't directly comparable since Angular is a framework and Clojurescript is a language, but I think that the Clojurescript React libraries all have quite similar philosophies and narrowing it down to just one would needlessly narrow the scope of the discussion.

I think that though TypeScript has static type-checking, immutability is probably still going to prevent more bugs if the choice is between one or the other, and that diligent usage of clojure-spec can provide assurances comparable to TypeScript's type system. While it's true that immutability can also be used in Typescript, I find that the language doesn't quite fit the paradigm as well, and so it tends to be quite clumsy in practice.

Obviously the list goes on, but I'd like to hear some other people's thoughts on the matter. For or against.

The app itself is targeted at businesses and is quite heavy on user interaction. It's essentially an editor of sorts where new features need to be implemented often to accommodate new features on the back-end. This means that the code must be flexible to refactors and generalized enough so that a change doesn't propagate too deeply or widely but can be handled in a relatively contained part of the application. I think I've figured out how to do that with Clojurescript. Not so sure about Angular, though I'm sure it's not impossible.

Submitted August 13, 2017 at 05:24AM by Cljuk
via reddit


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s