简体   繁体   中英

Client-side MVC frameworks for ClojureScript

I'm trying to choose a library for client-side MVC in ClojureScript. Here's are the ClojureScript libraries I've found so far:

  1. WebFUI ( https://github.com/drcode/webfui )
  2. Enfocus: ( http://ckirkendall.github.io/enfocus-site/ )
  3. Pedestal ( http://pedestal.io )
  4. Ducttape ( https://github.com/hozumi/ducttape.cljs )
  5. C2 ( http://keminglabs.com/c2/ ) It seems this can be used as a DOM framework.

How should I choose between them? Also, how will they compare to using AngularJS or Backbone from ClojureScript?

This is not exactly a complete framework, maybe just the V of the client side MVC but it worth to keep an eye of it.

https://github.com/swannodette/om

A ClojureScript interface to Facebook's React

Om allows users to represent their UIs simply as EDN. Because ClojureScript data is immutable data, Om can always rapidly re-render the UI from the root. Thus Om UIs are out of the box snapshotable and undoable and these operations have no implementation complexity and little overhead.

Please don't miss this read http://swannodette.github.io/2013/12/31/time-travel/

Ganelon (which I am author of) is a Clojure web microframework built on top of Ring/Compojure.

It is not exactly client-side MVC, as in general it provides a simple mechanism, that allows us to:

  1. invoke XHR request from a thin JavaScript layer (eg on link click or form submit)
  2. return JSON response containing operations to be performed (eg update DIV, display modal, etc.)
  3. perform operations from step 2 through a thin JavaScript layer

Docs & demo are available here: http://ganelon.tomeklipski.com .

I am the author of Coils, another Client Side Clojure framework:

https://github.com/zubairq/coils

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM