Module mogwai::utils [−][src]
Expand description
Helpers and utilities.
Functions
Return the DOM body.
Return the DOM web_sys::Document
Sets a static rust closure to be called with window.requestAnimationFrame
.
The given function may return whether or not this function should be rescheduled.
If the function returns true
it will be rescheduled. Otherwise it will not.
The static rust closure takes one parameter which is a timestamp representing the
number of milliseconds since the application’s load.
See https://developer.mozilla.org/en-US/docs/Web/API/DOMHighResTimeStamp
for more info.
Set a callback closure to be called in a given number of milliseconds.
Sets a static rust closure to be called after a given amount of milliseconds.
The given function may return whether or not this timeout should be rescheduled.
If the function returns true
it will be rescheduled. Otherwise it will not.
Return the DOM web_sys::Window
.