Chapter 4Add ClojureScript

In the preceding chapters you wrote a typical web application and learned how its components interact with one another. For example, you now know how to manage the routes, write HTML templates, and use sessions to manage user state. In this chapter we’ll look at ClojureScript and see how to use it to improve the way we write web applications.

As you’ve probably noticed, the separation between the client and the server portions of the application is not enforced. If we’re not careful, we could easily end up with tightly coupled client and server components. This could become a problem if we want to add a different client later on—for example, if we decided to create a native mobile version of our application.

Get Web Development with Clojure, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.