package fmlib_js
Library for easy compilation from ocaml to javascript
Install
Dune Dependency
Authors
Maintainers
Sources
0.4.0.tar.gz
sha256=b54320cbe9bddac9ff88654e1d8ffea1d2eecb48aa668f3483f26f80c7954531
md5=28a93cbd62d5debe496759e8e954848b
doc/fmlib_js/Fmlib_js/Timer/index.html
Module Fmlib_js.Timer
One shot timers and interval timers
val set : (unit -> unit) -> int -> timer
set callback millis
Start a one shot timer which runs millis
milliseconds and after that executes callback ()
.
The function returns a timer
object which can be used to stop the timer.
val clear : timer -> unit
clear timer
Stop the timer timer
. The call has no effect if timer
has already fired.
val set_interval : (unit -> unit) -> int -> interval
set_interval callback millis
Start a timer which executes callback ()
every millis
milliseconds.
The function returns an interval
object which can be used to stop the timer.
val clear_interval : interval -> unit
clear_interval timer
Stop the interval timer timer
.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>