package jsoo-react

  1. Overview
  2. Docs
type element = private Ojs.t

A React element

val element_of_js : Ojs.t -> element

Conversion function for gen_js_api

val element_to_js : element -> Ojs.t

Conversion function for gen_js_api

val null : element

A React element that will render the null value

val string : string -> element
val int : int -> element
val float : float -> element
type 'a option_undefined = 'a option
type 'a js_nullable = 'a Js_of_ocaml.Js.Opt.t
val js_nullable_of_js : (Ojs.t -> 'value) -> Ojs.t -> 'value js_nullable
val js_nullable_to_js : ('value -> Ojs.t) -> 'value js_nullable -> Ojs.t
type ('props, 'return) componentLike = 'props -> 'return
type 'props component = ('props, element) componentLike
val component_of_js : 'a -> 'a
val component_to_js : 'a -> 'a
type ('input, 'output) callback = 'input -> 'output
val create_element : 'props component -> 'props -> element
val create_element_variadic : 'props component -> 'props -> element list -> element
val clone_element : element -> 'props -> element
val use_effect_always : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> unit
val use_effect_once : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> unit
val use_effect1 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> 'a -> unit
val use_effect2 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b) -> unit
val use_effect3 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b * 'c) -> unit
val use_effect4 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b * 'c * 'd) -> unit
val use_effect5 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b * 'c * 'd * 'e) -> unit
val use_effect6 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b * 'c * 'd * 'e * 'f) -> unit
val use_effect7 : ?before_render:bool -> (unit -> (unit -> unit) option_undefined) -> ('a * 'b * 'c * 'd * 'e * 'f * 'g) -> unit
val use_callback1 : ('input, 'output) callback -> 'a -> ('input, 'output) callback
val use_callback2 : ('input, 'output) callback -> ('a * 'b) -> ('input, 'output) callback
val use_callback3 : ('input, 'output) callback -> ('a * 'b * 'c) -> ('input, 'output) callback
val use_callback4 : ('input, 'output) callback -> ('a * 'b * 'c * 'd) -> ('input, 'output) callback
val use_callback5 : ('input, 'output) callback -> ('a * 'b * 'c * 'd * 'e) -> ('input, 'output) callback
val use_callback6 : ('input, 'output) callback -> ('a * 'b * 'c * 'd * 'e * 'f) -> ('input, 'output) callback
val use_callback7 : ('input, 'output) callback -> ('a * 'b * 'c * 'd * 'e * 'f * 'g) -> ('input, 'output) callback
val use_memo1 : (unit -> 'value) -> 'a -> 'value
val use_memo2 : (unit -> 'value) -> ('a * 'b) -> 'value
val use_memo3 : (unit -> 'value) -> ('a * 'b * 'c) -> 'value
val use_memo4 : (unit -> 'value) -> ('a * 'b * 'c * 'd) -> 'value
val use_memo5 : (unit -> 'value) -> ('a * 'b * 'c * 'd * 'e) -> 'value
val use_memo6 : (unit -> 'value) -> ('a * 'b * 'c * 'd * 'e * 'f) -> 'value
val use_memo7 : (unit -> 'value) -> ('a * 'b * 'c * 'd * 'e * 'f * 'g) -> 'value
val use_state : (unit -> 'state) -> 'state * (('state -> 'state) -> unit)
val use_reducer : init:(unit -> 'state) -> ('state -> 'action -> 'state) -> 'state * ('action -> unit)
module Ref : sig ... end
val use_ref : 'value -> 'value Ref.t
module Context : sig ... end
val use_context : 'value Context.t -> 'value
module Children : sig ... end
module Fragment : sig ... end
module StrictMode : sig ... end
val memo : ?compare:('props -> 'props -> bool) -> 'props component -> 'props component
val set_display_name : 'props component -> string -> unit
module Hooks : sig ... end
module Dom : sig ... end
module Event : sig ... end
module Router : sig ... end
OCaml

Innovation. Community. Security.