package js_of_ocaml

  1. Overview
  2. Docs
Compiler from OCaml bytecode to JavaScript

Install

dune-project
 Dependency

Authors

Maintainers

Sources

js_of_ocaml-6.4.1.tbz
sha256=e59bbffcaefaba3191620556514b7f53bb3249e3f881a070d72724234dffd819
sha512=bb470f316f9c81a3b2b8dedd0b0f18f8e06beb48dd70df1d9f846de90ffab439cab5ef7a93a8166af0998068b06097e8319bc0d9f4f23a7159b0de8b3b515746

doc/js_of_ocaml/Js_of_ocaml/Dom_html/index.html

Module Js_of_ocaml.Dom_htmlSource

DOM HTML binding

This is a partial binding to the DOM HTML API.

CSS style declaration

Sourceclass type cssStyleDeclaration = object ... end

Events

Sourcetype (-'a, -'b) event_listener = ('a, 'b) Dom.event_listener

The type of event listener functions. The first type parameter 'a is the type of the target object; the second parameter 'b is the type of the event object.

Sourcetype mouse_button =
  1. | No_button
  2. | Left_button
  3. | Middle_button
  4. | Right_button
Sourcetype delta_mode =
  1. | Delta_pixel
  2. | Delta_line
  3. | Delta_page
Sourcetype domStringMap

DOMStringMap used for the dataset property. Use the DomStringMap module for typed access.

Sourceclass type event = object ... end
Sourceclass type 'a customEvent = object ... end
Sourceclass type focusEvent = object ... end
Sourceclass type mouseEvent = object ... end
Sourceclass type keyboardEvent = object ... end
Sourceclass type wheelEvent = object ... end
Sourceclass type touchEvent = object ... end
Sourceclass type touchList = object ... end
Sourceclass type touch = object ... end
Sourceclass type submitEvent = object ... end
Sourceclass type dragEvent = object ... end
Sourceclass type clipboardEvent = object ... end
Sourceclass type toggleEvent = object ... end
Sourceclass type mediaQueryListEvent = object ... end
Sourceclass type dataTransfer = object ... end
Sourceclass type eventTarget = object ... end

Common properties of event target objects: onclick, onkeypress, ...

Sourceclass type popStateEvent = object ... end
Sourceclass type pointerEvent = object ... end
Sourceclass type storageEvent = object ... end
Sourceclass type storage = object ... end

Storage

Sourceclass type hashChangeEvent = object ... end
Sourceclass type animationEvent = object ... end
Sourceclass type transitionEvent = object ... end
Sourceclass type mediaEvent = object ... end
Sourceclass type messageEvent = object ... end
Sourceclass type staticRange = object ... end
Sourceclass type compositionEvent = object ... end
Sourceclass type inputEvent = object ... end
Sourceclass type errorEvent = object ... end
Sourceclass type progressEvent = object ... end
Sourceclass type beforeUnloadEvent = object ... end
Sourceclass type pageTransitionEvent = object ... end

HTML elements

Sourceclass type nodeSelector = object ... end
Sourceclass type tokenList = object ... end
Sourceclass type shadowRootInit = object ... end
Sourceclass type shadowRoot = object ... end
Sourceclass type animation = object ... end
Sourceclass type animationTimeline = object ... end
Sourceclass type documentTimeline = object ... end
Sourceclass type animationEffect = object ... end
Sourceclass type keyframeEffect = object ... end
Sourceclass type computedKeyframe = object ... end
Sourceclass type optionalEffectTiming = object ... end
Sourceclass type computedEffectTiming = object ... end
Sourceclass type keyframeAnimationOptions = object ... end
Sourceclass type animationPlaybackEvent = object ... end
Sourceclass type scrollToOptions = object ... end
Sourceclass type scrollIntoViewOptions = object ... end
Sourceclass type focusOptions = object ... end
Sourceclass type showPopover_options = object ... end
Sourceclass type togglePopover_options = object ... end
Sourceclass type element = object ... end

Properties common to all HTML elements

Sourceclass type clientRect = object ... end

Rectangular box (used for element bounding boxes)

Sourceclass type clientRectList = object ... end
Sourceclass type 'node collection = 'node Js_of_ocaml__.Dom.collection

Collection of HTML elements. Alias for Dom.collection.

Sourceclass type headElement = object ... end
Sourceclass type linkElement = object ... end
Sourceclass type titleElement = object ... end
Sourceclass type metaElement = object ... end
Sourceclass type baseElement = object ... end
Sourceclass type styleElement = object ... end
Sourceclass type validityState = object ... end

Result of the constraint validation API on form-associated elements.

Sourceclass type submitterElement = object ... end
Sourceclass type formElement = object ... end
Sourceclass type labelElement = object ... end
Sourceclass type optGroupElement = object ... end
Sourceclass type optionElement = object ... end
Sourceclass type dataListElement = object ... end
Sourceclass type selectElement = object ... end
Sourceclass type inputElement = object ... end
Sourceclass type textAreaElement = object ... end
Sourceclass type buttonElement = object ... end
Sourceclass type fieldSetElement = object ... end
Sourceclass type legendElement = object ... end
Sourceclass type outputElement = object ... end
Sourceclass type progressElement = object ... end
Sourceclass type meterElement = object ... end
Sourceclass type templateElement = object ... end
Sourceclass type slotElement = object ... end
Sourceclass type sourceElement = object ... end
Sourcetype trackReadyState =
  1. | TRACK_NONE
  2. | TRACK_LOADING
  3. | TRACK_LOADED
  4. | TRACK_ERROR
Sourceclass type trackElement = object ... end
Sourceclass type timeElement = object ... end
Sourceclass type dataElement = object ... end
Sourceclass type dialogElement = object ... end
Sourceclass type quoteElement = object ... end
Sourceclass type modElement = object ... end
Sourceclass type anchorElement = object ... end
Sourceclass type detailsElement = object ... end
Sourceclass type imageElement = object ... end
Sourceclass type objectElement = object ... end
Sourceclass type paramElement = object ... end
Sourceclass type areaElement = object ... end
Sourceclass type mapElement = object ... end
Sourceclass type scriptElement = object ... end
Sourceclass type embedElement = object ... end
Sourceclass type tableCellElement = object ... end
Sourceclass type tableRowElement = object ... end
Sourceclass type tableColElement = object ... end
Sourceclass type tableSectionElement = object ... end
Sourceclass type tableElement = object ... end
Sourceclass type timeRanges = object ... end
Sourcetype networkState =
  1. | NETWORK_EMPTY
  2. | NETWORK_IDLE
  3. | NETWORK_LOADING
  4. | NETWORK_NO_SOURCE
Sourcetype readyState =
  1. | HAVE_NOTHING
  2. | HAVE_METADATA
  3. | HAVE_CURRENT_DATA
  4. | HAVE_FUTURE_DATA
  5. | HAVE_ENOUGH_DATA
Sourceclass type mediaElement = object ... end
Sourceclass type audioElement = object ... end
Sourceclass type videoElement = object ... end

Canvas object

Sourcetype context
Sourceval _2d_ : context
Sourcetype canvasPattern
Sourceclass type canvasElement = object ... end
Sourceclass type canvasRenderingContext2D = object ... end
Sourceclass type canvasGradient = object ... end
Sourceclass type textMetrics = object ... end
Sourceclass type imageData = object ... end
Sourceclass type canvasPixelArray = object ... end
Sourceval pixel_get : canvasPixelArray Js.t -> int -> int
Sourceval pixel_set : canvasPixelArray Js.t -> int -> int -> unit
Sourcetype boundary_points_comparison =
  1. | Start_to_start
  2. | Start_to_end
  3. | End_to_end
  4. | End_to_start
Sourceclass type range = object ... end

Object representing a range *

Sourceclass type selection = object ... end

Information on current selection

Document objects

Sourceclass type document = object ... end
Sourceval document : document Js.t

The current document

Sourceval getElementById_opt : string -> element Js.t option

getElementById_opt id returns the element with the id id in the current document. It returns None if there are no such element

Sourceval getElementById_exn : string -> element Js.t

getElementById_exn id returns the element with the id id in the current document. It raises if there are no such element

Sourceval getElementById_coerce : string -> (element Js.t -> 'a Js.opt) -> 'a option

getElementById_coerce id coerce returns the element with the id id in the current document and attempt to coerce it using the provided coerce function. It returns None if there are no such element or if the coerce function returns Js.none. Typical usage is the following:

  match Dom_html.getElementById_coerce "myinput" Dom_html.CoerceTo.input with
  | None -> ..
  | Some input -> ..
Sourceval getElementById : string -> element Js.t

getElementById id returns the element with the id id in the current document. It raises Not_found if there are no such element

Window objects

Sourceclass type location = object ... end

Location information

Sourceval location_origin : location Js.t -> Js.js_string Js.t
Sourceclass type history = object ... end

Browser history information

Sourceclass type undoManager = object ... end

Undo manager

Sourceclass type navigator = object ... end

Navigator information

Sourceclass type screen = object ... end
Sourceclass type applicationCache = object ... end
Sourcetype interval_id
Sourcetype timeout_id
Sourcetype animation_frame_request_id
Sourceclass type _URL = object ... end
Sourceclass type mediaQueryList = object ... end
Sourceclass type windowPostMessageOptions = object ... end

Options for Window.postMessage.

Sourceclass type window = object ... end

Specification of window objects

Sourceval window : window Js.t

The current window

Sourceclass type frameSetElement = object ... end
Sourceclass type frameElement = object ... end
Sourceclass type iFrameElement = object ... end

Event handlers

Sourceval no_handler : ('a, 'b) event_listener

see Dom.no_handler

Sourceval handler : ((event Js.t as 'b) -> bool Js.t) -> ('a, 'b) event_listener

see Dom.handler

Sourceval full_handler : ('a -> (event Js.t as 'b) -> bool Js.t) -> ('a, 'b) event_listener

see Dom.full_handler

Sourceval listener : ((event Js.t as 'b) -> unit) -> ('a, 'b) event_listener

see Dom.listener

Sourceval full_listener : ('a -> (event Js.t as 'b) -> unit) -> ('a, 'b) event_listener

see Dom.full_listener

Sourceval invoke_handler : ('a, 'b) event_listener -> 'a -> 'b -> bool Js.t

see Dom.invoke_handler

Sourceval eventTarget : event Js.t -> element Js.t

see Dom.eventTarget

Sourceval eventRelatedTarget : mouseEvent Js.t -> element Js.t Js.opt

Returns this event related target.

Sourcemodule Event : sig ... end

Event types: mousedown, keypress, ...

Sourcetype event_listener_id = Dom.event_listener_id
Sourceval addEventListenerWithOptions : (eventTarget Js.t as 'a) -> 'b Event.typ -> ?capture:bool Js.t -> ?once:bool Js.t -> ?passive:bool Js.t -> ('a, 'b) event_listener -> event_listener_id

Add an event listener. This function matches the option-object variant of the addEventListener DOM method, except that it returns an id for removing the listener.

Sourceval addEventListener : (eventTarget Js.t as 'a) -> 'b Event.typ -> ('a, 'b) event_listener -> bool Js.t -> event_listener_id

Add an event listener. This function matches the useCapture boolean variant of the addEventListener DOM method, except that it returns an id for removing the listener.

Sourceval removeEventListener : event_listener_id -> unit

Remove the given event listener.

Sourceval addMousewheelEventListenerWithOptions : eventTarget Js.t -> ?capture:bool Js.t -> ?once:bool Js.t -> ?passive:bool Js.t -> (mouseEvent Js.t -> dx:int -> dy:int -> bool Js.t) -> event_listener_id

Add a wheel event listener with option-object variant of the addEventListener DOM method. The callback is provided the event and the numbers of ticks the mouse wheel moved. Positive means down / right.

Sourceval addMousewheelEventListener : eventTarget Js.t -> (mouseEvent Js.t -> dx:int -> dy:int -> bool Js.t) -> bool Js.t -> event_listener_id

Add a wheel event listener with the useCapture boolean variant of the addEventListener DOM method. The callback is provided the event and the numbers of ticks the mouse wheel moved. Positive means down / right.

Sourceval createCustomEvent : ?bubbles:bool -> ?cancelable:bool -> ?detail:'a -> 'a customEvent Js.t Event.typ -> 'a customEvent Js.t

See Dom.createCustomEvent

Mouse event helper functions

Sourceval buttonPressed : mouseEvent Js.t -> mouse_button

Position helper functions

Sourceval eventAbsolutePosition : mouseEvent Js.t -> float * float

Returns the absolute position of the mouse pointer.

Sourceval elementClientPosition : element Js.t -> int * int

Position of an element relative to the viewport

Sourceval getDocumentScroll : unit -> float * float

Viewport top/left position

Key event helper functions

Sourcemodule Keyboard_code : sig ... end

Use Keyboard_code when you want to identify a key that the user pressed. This should be invoked for keydown and keyup events, not keypress events.

Sourcemodule Keyboard_key : sig ... end

Use Keyboard_key when you want to identify the character that the user typed. This should only be invoked on keypress events, not keydown or keyup events.

Helper functions for creating HTML elements

Sourceval createHtml : document Js.t -> htmlElement Js.t
Sourceval createHead : document Js.t -> headElement Js.t
Sourceval createTitle : document Js.t -> titleElement Js.t
Sourceval createMeta : document Js.t -> metaElement Js.t
Sourceval createBase : document Js.t -> baseElement Js.t
Sourceval createStyle : document Js.t -> styleElement Js.t
Sourceval createBody : document Js.t -> bodyElement Js.t
Sourceval createForm : document Js.t -> formElement Js.t
Sourceval createOptgroup : document Js.t -> optGroupElement Js.t
Sourceval createOption : document Js.t -> optionElement Js.t
Sourceval createSelect : ?_type:Js.js_string Js.t -> ?name:Js.js_string Js.t -> document Js.t -> selectElement Js.t
Sourceval createInput : ?_type:Js.js_string Js.t -> ?name:Js.js_string Js.t -> document Js.t -> inputElement Js.t
Sourceval createTextarea : ?_type:Js.js_string Js.t -> ?name:Js.js_string Js.t -> document Js.t -> textAreaElement Js.t
Sourceval createButton : ?_type:Js.js_string Js.t -> ?name:Js.js_string Js.t -> document Js.t -> buttonElement Js.t
Sourceval createLabel : document Js.t -> labelElement Js.t
Sourceval createFieldset : document Js.t -> fieldSetElement Js.t
Sourceval createLegend : document Js.t -> legendElement Js.t
Sourceval createLi : document Js.t -> liElement Js.t
Sourceval createDialog : document Js.t -> dialogElement Js.t
Sourceval createDiv : document Js.t -> divElement Js.t
Sourceval createEmbed : document Js.t -> embedElement Js.t
Sourceval createBlockquote : document Js.t -> quoteElement Js.t
Sourceval createPre : document Js.t -> preElement Js.t
Sourceval createBr : document Js.t -> brElement Js.t
Sourceval createHr : document Js.t -> hrElement Js.t
Sourceval createIns : document Js.t -> modElement Js.t
Sourceval createDel : document Js.t -> modElement Js.t
Sourceval createObject : document Js.t -> objectElement Js.t
Sourceval createParam : document Js.t -> paramElement Js.t
Sourceval createMap : document Js.t -> mapElement Js.t
Sourceval createArea : document Js.t -> areaElement Js.t
Sourceval createScript : document Js.t -> scriptElement Js.t
Sourceval createTable : document Js.t -> tableElement Js.t
Sourceval createColgroup : document Js.t -> tableColElement Js.t
Sourceval createSub : document Js.t -> element Js.t
Sourceval createSup : document Js.t -> element Js.t
Sourceval createSpan : document Js.t -> element Js.t
Sourceval createTt : document Js.t -> element Js.t
Sourceval createI : document Js.t -> element Js.t
Sourceval createB : document Js.t -> element Js.t
Sourceval createBig : document Js.t -> element Js.t
Sourceval createSmall : document Js.t -> element Js.t
Sourceval createEm : document Js.t -> element Js.t
Sourceval createStrong : document Js.t -> element Js.t
Sourceval createCite : document Js.t -> element Js.t
Sourceval createDfn : document Js.t -> element Js.t
Sourceval createCode : document Js.t -> element Js.t
Sourceval createSamp : document Js.t -> element Js.t
Sourceval createKbd : document Js.t -> element Js.t
Sourceval createVar : document Js.t -> element Js.t
Sourceval createAbbr : document Js.t -> element Js.t
Sourceval createDd : document Js.t -> element Js.t
Sourceval createDt : document Js.t -> element Js.t
Sourceval createNoscript : document Js.t -> element Js.t
Sourceval createAddress : document Js.t -> element Js.t
Sourceval createFrameset : document Js.t -> frameSetElement Js.t
Sourceval createFrame : document Js.t -> frameElement Js.t
Sourceval createIframe : document Js.t -> iFrameElement Js.t
Sourceval createAudio : document Js.t -> audioElement Js.t
Sourceval createVideo : document Js.t -> videoElement Js.t
Sourceval createOutput : document Js.t -> outputElement Js.t
Sourceval createProgress : document Js.t -> progressElement Js.t
Sourceval createMeter : document Js.t -> meterElement Js.t
Sourceval createDatalist : document Js.t -> dataListElement Js.t
Sourceval createTemplate : document Js.t -> templateElement Js.t
Sourceval createSlot : document Js.t -> slotElement Js.t
Sourceval createPicture : document Js.t -> pictureElement Js.t
Sourceval createSource : document Js.t -> sourceElement Js.t
Sourceval createTrack : document Js.t -> trackElement Js.t
Sourceval createTime : document Js.t -> timeElement Js.t
Sourceval createData : document Js.t -> dataElement Js.t
Sourceexception Canvas_not_available
Sourceval createCanvas : document Js.t -> canvasElement Js.t

Coercion functions

Coercion from a general DOM element to an HTML element. (Unsafe in general.)

Sourcetype taggedElement =
  1. | A of anchorElement Js.t
  2. | Area of areaElement Js.t
  3. | Audio of audioElement Js.t
  4. | Base of baseElement Js.t
  5. | Blockquote of quoteElement Js.t
  6. | Body of bodyElement Js.t
  7. | Br of brElement Js.t
  8. | Button of buttonElement Js.t
  9. | Canvas of canvasElement Js.t
  10. | Caption of tableCaptionElement Js.t
  11. | Col of tableColElement Js.t
  12. | Colgroup of tableColElement Js.t
  13. | Del of modElement Js.t
  14. | Dialog of dialogElement Js.t
  15. | Div of divElement Js.t
  16. | Dl of dListElement Js.t
  17. | Embed of embedElement Js.t
  18. | Fieldset of fieldSetElement Js.t
  19. | Form of formElement Js.t
  20. | Frameset of frameSetElement Js.t
  21. | Frame of frameElement Js.t
  22. | H1 of headingElement Js.t
  23. | H2 of headingElement Js.t
  24. | H3 of headingElement Js.t
  25. | H4 of headingElement Js.t
  26. | H5 of headingElement Js.t
  27. | H6 of headingElement Js.t
  28. | Head of headElement Js.t
  29. | Hr of hrElement Js.t
  30. | Html of htmlElement Js.t
  31. | Iframe of iFrameElement Js.t
  32. | Img of imageElement Js.t
  33. | Input of inputElement Js.t
  34. | Ins of modElement Js.t
  35. | Label of labelElement Js.t
  36. | Legend of legendElement Js.t
  37. | Li of liElement Js.t
  38. | Map of mapElement Js.t
  39. | Meta of metaElement Js.t
  40. | Object of objectElement Js.t
  41. | Ol of oListElement Js.t
  42. | Optgroup of optGroupElement Js.t
  43. | Option of optionElement Js.t
  44. | P of paragraphElement Js.t
  45. | Param of paramElement Js.t
  46. | Pre of preElement Js.t
  47. | Q of quoteElement Js.t
  48. | Script of scriptElement Js.t
  49. | Select of selectElement Js.t
  50. | Style of styleElement Js.t
  51. | Table of tableElement Js.t
  52. | Tbody of tableSectionElement Js.t
  53. | Td of tableCellElement Js.t
  54. | Textarea of textAreaElement Js.t
  55. | Tfoot of tableSectionElement Js.t
  56. | Th of tableCellElement Js.t
  57. | Thead of tableSectionElement Js.t
  58. | Title of titleElement Js.t
  59. | Tr of tableRowElement Js.t
  60. | Ul of uListElement Js.t
  61. | Video of videoElement Js.t
  62. | Other of element Js.t
Sourceval opt_tagged : element Js.t Js.opt -> taggedElement option
Sourcetype taggedEvent =
  1. | MouseEvent of mouseEvent Js.t
  2. | KeyboardEvent of keyboardEvent Js.t
  3. | MessageEvent of messageEvent Js.t
  4. | MousewheelEvent of mousewheelEvent Js.t
  5. | PopStateEvent of popStateEvent Js.t
  6. | OtherEvent of event Js.t
Sourceval taggedEvent : event Js.t -> taggedEvent
Sourceval opt_taggedEvent : event Js.t Js.opt -> taggedEvent option
Sourceval stopPropagation : event Js.t -> unit
Sourcemodule DomStringMap : sig ... end

Typed access to domStringMap (the type of Element.dataset).

Sourceval attachShadow : ?delegatesFocus:bool Js.t -> mode:Js.js_string Js.t -> element Js.t -> shadowRoot Js.t

Wrapper for Element.attachShadow(init) taking labeled arguments.

Sourceval scrollIntoView : ?behavior:Js.js_string Js.t -> ?block:Js.js_string Js.t -> ?inline:Js.js_string Js.t -> element Js.t -> unit

Wrapper for Element.scrollIntoView(options) taking labeled arguments.

Sourceval focus : ?preventScroll:bool Js.t -> element Js.t -> unit

Wrapper for HTMLElement.focus(options) taking labeled arguments.

Sourceval showPopover : ?source:element Js.t -> element Js.t -> unit

Wrapper for Element.showPopover(options) taking labeled arguments.

Sourceval hidePopover : element Js.t -> unit

Wrapper for Element.hidePopover().

Sourceval togglePopover : ?force:bool Js.t -> ?source:element Js.t -> element Js.t -> bool Js.t

Wrapper for Element.togglePopover(options) taking labeled arguments. Returns the new open state.

Sourceval postMessage : ?transfer:Js.Unsafe.any Js.js_array Js.t -> ?targetOrigin:Js.js_string Js.t -> window Js.t -> 'a -> unit

Wrapper for window.postMessage(message, options) taking labeled arguments. When ~targetOrigin is omitted, the JavaScript default of "/" (same origin) applies.

Sourceval makeScrollToOptions : ?top:Js.number_t -> ?left:Js.number_t -> ?behavior:Js.js_string Js.t -> unit -> scrollToOptions Js.t

Smart constructor for scrollToOptions.

Sourceval makeKeyframeAnimationOptions : ?delay:Js.number_t -> ?endDelay:Js.number_t -> ?fill:Js.js_string Js.t -> ?iterationStart:Js.number_t -> ?iterations:Js.number_t -> ?duration:Js.number_t -> ?direction:Js.js_string Js.t -> ?easing:Js.js_string Js.t -> ?id:Js.js_string Js.t -> ?composite:Js.js_string Js.t -> ?pseudoElement:Js.js_string Js.t Js.opt -> ?timeline:animationTimeline Js.t Js.opt -> unit -> keyframeAnimationOptions Js.t

Smart constructor for keyframeAnimationOptions.

Sourceval makeOptionalEffectTiming : ?delay:Js.number_t -> ?endDelay:Js.number_t -> ?fill:Js.js_string Js.t -> ?iterationStart:Js.number_t -> ?iterations:Js.number_t -> ?duration:Js.number_t -> ?direction:Js.js_string Js.t -> ?easing:Js.js_string Js.t -> unit -> optionalEffectTiming Js.t

Smart constructor for optionalEffectTiming.

Sourcemodule CoerceTo : sig ... end

HTMLElement

Sourcetype timeout_id_safe
Sourceval setTimeout : (unit -> unit) -> float -> timeout_id_safe

Same as Dom_html.window##setTimeout cb ms but prevents overflow with delay greater than 24 days.

Sourceval clearTimeout : timeout_id_safe -> unit
Sourceval onload : (unit -> unit) -> unit

Register a callback to run when the page finishes loading. If the page has already loaded (e.g. when running as WebAssembly), the callback is invoked immediately.

Sourceval js_array_of_collection : element collection Js.t -> element Js.t Js.js_array Js.t

Convert a Dom_html.collection to a Js array

Deprecated function.

Sourceval _requestAnimationFrame : (unit -> unit) Js.callback -> unit

Call the appropriate requestAnimationFrame method variant (depending on the navigator), or sleep for a short amount of time when there no such method is provided. We currently prefix the function name with as underscore as the interface of this function is not completely standardized yet. Thus, we leave the room to a function with a possibly refined type.

This function is deprecated. Use the requestAnimationFrame of the window object instead.

  • deprecated [since 2.6] Use [Dom_html.window##requestAnimationFrame] instead.