Parameter M.1-Component
module Input : Core_kernel.T
module Model : Core_kernel.T
module Action : sig ... end
module Result : Core_kernel.T
val apply_action : inject:(Action.t -> Event.t) -> schedule_event:(Event.t -> unit) -> Input.t -> Model.t -> Action.t -> Model.t
apply_action
is a transformation from a model and an action into a new model. During the transformation, the Component can also emit more actions viaschedule_event
or use Async to arrange forschedule_event
to be called later.