package bonsai

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
include module type of Virtual_dom.Vdom.Effect
module type Handler = Ui_effect.Handler
type !'a t = 'a Ui_effect.t = ..
type t +=
  1. | Ignore : unit t
  2. | Many : unit t list -> unit t
val (>>=) : 'a t -> ('a -> 'b t) -> 'b t
val (>>|) : 'a t -> ('a -> 'b) -> 'b t
module Monad_infix = Ui_effect.Monad_infix
val bind : 'a t -> f:('a -> 'b t) -> 'b t
val return : 'a -> 'a t
val map : 'a t -> f:('a -> 'b) -> 'b t
val join : 'a t t -> 'a t
val ignore_m : 'a t -> unit t
val all : 'a t list -> 'a list t
val all_unit : unit t list -> unit t
module Let_syntax = Ui_effect.Let_syntax
val never : 'a t
val lazy_ : 'a t Core.Lazy.t -> 'a t
val print_s : Core.Sexp.t -> unit t
val of_sync_fun : ('query -> 'result) -> 'query -> 'result t
module Define = Ui_effect.Define
module Define1 = Ui_effect.Define1
module Private = Ui_effect.Private
module For_testing = Ui_effect.For_testing
module type Visibility_handler = sig ... end
module type S = sig ... end
type t +=
  1. | Viewport_changed
  2. | Stop_propagation
  3. | Stop_immediate_propagation
  4. | Prevent_default
val sequence_as_sibling : unit t -> unless_stopped:(unit -> unit t) -> unit t
module Define_visibility (VH : Visibility_handler) : sig ... end
module Expert : sig ... end
val of_deferred_fun : ('query -> 'response Async_kernel.Deferred.t) -> 'query -> 'response t

of_deferred_fun is a way to convert from a deferred-returning function to an effect-returning function. This function is commonly used to wrap RPC calls. Memory is allocated permanently every time that of_deferred_fun is called, so be sure to re-use the function inside the Staged.t!

OCaml

Innovation. Community. Security.