Reagi and other CES frameworks

Back in Chapter 4, Introduction to core.async, we had an overview of the main differences between core.async and CES. Another question that might have arisen in this chapter is this: how do we decide which CES framework to use?

The answer is less clear than before and often depends on the specifics of the tool being looked at. We have learned about two such tools so far: Reactive Extensions (encompassing RxJS, RxJava, and RxClojure) and Reagi.

Reactive Extensions (Rx) is a much more mature framework. Its first version for the .NET platform was released in 2011 and the ideas in it have since evolved substantially.

Additionally, ports for other platforms such as RxJava are being heavily used in production by big names such as Netflix.

A drawback of Rx is that if you would like to use it both in the browser and on the server, you have to use two separate frameworks, RxJS and RxJava, respectively. While they do share the same API, they are different codebases, which can incur bugs that might have been solved in one port but not yet in another.

For Clojure developers, it also means relying more on interoperability to interact with the full API of Rx.

Reagi, on the other hand, is a new player in this space but builds on the solid foundation laid out by core.async. It is fully developed in Clojure and solves the in-browser/on-server issue by compiling to both Clojure and ClojureScript.

Reagi also allows seamless integration with core.async via functions such as port and subscribe, which allow channels to be created from event streams.

Moreover, the use of core.async in ClojureScript applications is becoming ubiquitous, so chances are you already have it as a dependency. This makes Reagi an attractive option for the times when we need a higher level of abstraction than the one provided by core.async.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.145.50.222