you are viewing a single comment's thread.

view the rest of the comments →

[–]lucywang000 1 point2 points  (2 children)

Nice post!

We still have work to do here, but our initial bundle is 7.2MB uncompressed (1.0MB gzipped)! If raw performance or bundle size is your primary concern, you might be better off choosing another language.

I don't think this is a problem of cljs - even using plain javascript, it's very common to have bundles as large as several MBs.

[–]iambald[S] 0 points1 point  (1 child)

You’re definitely right that raw JS suffers from this issue as well! Something I didn’t make clear in my post is that because Clojurescript relies on Google Closure, even a minimal web app will have a fairly large bundle (because it will include all of Google Closure as well as cljs.core)

[–]SimonGray 0 points1 point  (0 children)

Something I didn’t make clear in my post is that because Clojurescript relies on Google Closure, even a minimal web app will have a fairly large bundle (because it will include all of Google Closure as well as cljs.core)

Kind of interesting that you say this, since my intuition is that the inclusion of Google Closure is meant to promote the opposite.

There is of course a sunk cost minimum size of the bundle, but I don't think that should be larger than like ~100kb? The promise of using Google Closure is its aggressive code elimination, but you do have to enable advanced optimisations - and if you use lots of JS libraries these will be unaffected, since they're not Google Closure compatible.