I found Svelte very interesting and started to experiment it with ClojureScript. For those who don’t know, the elevator pitch of Svelte is:
Svelte is a radical new approach to building user interfaces. Whereas traditional frameworks like React and Vue do the bulk of their work in the browser, Svelte shifts that work into a compile step that happens when you build your app.
Based on @thheller 's next-cljs, I created a hello world example in the link down below. Currently, this example can only spit out a static app (i.e., no reactivity, no props, and no states.) The approach is to use shadow-cljs’s
build-hook to generate the
*.svelte stub files that invoke the cljs functions.
The reasons for this post is to discuss:
- Are Svelte and ClojureScript a good fit?
- What is a good approach to building a ClojureScript Svelte web app (presumably with shadow-cljs)?
- Any feedback/idea?
- Project repo: https://github.com/dawran6/shadow-svelte