module Sharp_ticker:sig
..end
typetime_diff =
Sharp_core.time
type 'a
command =
| |
Once of |
(* |
Take the value after x seconds.
| *) |
| |
Every of |
(* |
Take the value every x seconds.
| *) |
| |
NTimes of |
(* |
Take the value every x seconds n times
then stops.
| *) |
val tick_manager : 'a command list ->
'a option Sharp_core.t * ('a command -> unit) * (unit -> unit)
val every : time_diff -> 'a -> 'a option Sharp_core.t * (unit -> unit)
val last_for : time_diff -> 'a option Sharp_core.t -> 'a option Sharp_core.t
Note that this does not bind any events. Hence, nothing is triggered
automatically after these x seconds. This signal should therefore be bound
to a ticker somehow before it is connected to a function like vdom
.