Clojurescript is very lightweight, just like Clojure itself. Clojurescript is much more lightweight when you compare it to other libraries

Bloat - not with Clojurescript

jQuery is bigger than Clojurescript and if you add persistent data structures via immutable.js then the Javascript app is nearly twice as big.

Size matters

The size of your client-side and mobile web apps really matters. Even 5G networks will not really fix the problem for mobile web apps.

Mobile web is broken - Code size matters

Its ironic that the article that talks about how broken the mobile web is provides a perfect example of why it is broken. When looking at the contents of this page there is 7Mb of Javascript to download.

Its a common pattern to just ship the whole libraries

Optimised Clojurescript - eliminating dead code

By changing the Clojurescript project.clj configuration file to include optimisation set to true, the compiler (Google Closure compiler) with eliminate any code that is not used. Typically reducing the size of the Javascript files generated by a huge factor.

Clojurescript code optimisation

See the section on Google Clojure library and tools to know more.

Modularised code

As you build bigger apps and especially single page apps, then you need to break up your Javascript into different sections to that you only need to load what you are using. By using modules in Clojurescript you can easily optimise your code for deployment

Modularised code

results matching ""

    No results matching ""