scalaz / scalaz-reactive

A high-performance, purely-functional library for reactive programming based on efficient incremental computation
Apache License 2.0
24 stars 10 forks source link

Make a simple example using current api #12

Closed VledicFranco closed 6 years ago

VledicFranco commented 6 years ago

Several other FRP libraries (Haskell) have simple examples, code one or two using our current API in a new package for now

kolov commented 6 years ago

I would recommend this as a starting point: https://wiki.haskell.org/FRP_explanation_using_reactive-banana.

It is a simple example with a lot of explanation about every step.

kolov commented 6 years ago

See the first example composing only events: TwoTickers. Now we need to add behaviours.

kolov commented 6 years ago

An example of an accumulation behaviour built from stdin input Event works, but using Behavour.ap() breaks the code. Behavour.ap() must be fixed

kolov commented 6 years ago

There are two simple examples - TwoTickers and Synthesizer.