module type M = Input signature for the module to be used from imperative changes.
It implements the data structure that will be usable through FRP.
The type of the data structure.
Actions indicate how to change the data structure: for instance, "`Add 42"
to add the int 42 to a set data structure.
val empty :
The initial state the data structure will be in.
val on_action :
('a * 'b) t ->
'a -> 'b action -> ('a * 'b) t
on_action is a function passed to a "fold" operation: from the current
state and an action, it creates a new state.
Here, 'a is an identifier for the source of the action. It is opaque but can
be used to find whether the source of the action was the same as the source
of a previous action (which is why it is stored in the datastructure).