Idris2Doc : Web.MVC.Cmd

Web.MVC.Cmd

(source)

Definitions

recordCmd : Type->Type
  A `Cmd` (abbreviation of "command") is a (typically effectful) computation
which might send an arbitrary number of events of type `e` to an event
handler synchronously or asynchronously.

Commands are used as the primary means of setting up (interactive) UI
components and running effectful computations.

Module `Web.MVC.View` provides various commands for creating, modifying
and deleting interactive DOM elements.

Module `Web.MVC.Animate` has commands for firing events at regular
intervals and for running animations.

Module `Web.MVC.Http` has commands for sending requests to and
firing events upon receiving responses from HTTP servers.

Totality: total
Visibility: public export
Constructor: 
C : ((e->JSIO ()) ->JSIO ()) ->Cmde

Projection: 
.run : Cmde-> (e->JSIO ()) ->JSIO ()

Hints:
FunctorCmd
Monoid (Cmde)
Semigroup (Cmde)
.run : Cmde-> (e->JSIO ()) ->JSIO ()
Totality: total
Visibility: public export
run : Cmde-> (e->JSIO ()) ->JSIO ()
Totality: total
Visibility: public export
batch : List (Cmde) ->Cmde
  Wraps a batch of commands in a single command by
installing each command sequentially.

This function is stack safe.

Totality: total
Visibility: export
cmd : JSIOe->Cmde
  Wrap an effectful computation in a command.

The produced result is fired synchronously.

Totality: total
Visibility: export
liftIO : IOe->Cmde
  Wrap an effectful computation in a command.

The produced result is fired synchronously.

Totality: total
Visibility: export
cmd_ : JSIO () ->Cmde
  Wrap an effectful computation in a command.

This will never fire an event.

Totality: total
Visibility: export
liftIO_ : IO () ->Cmde
  Wrap an effectful computation in a command.

This will never fire an event.

Totality: total
Visibility: export
pure : e->Cmde
  Fires the given event once, synchronously.

Totality: total
Visibility: export
noAction : Cmde
  A command that produces no event.

This will never fire an event.

Totality: total
Visibility: export
cmdIf : Bool-> Lazy (Cmde) ->Cmde
  Use the given command conditionally.

If the boolean flag is `False`, this will return the
empty command (`noAction`).

Totality: total
Visibility: export
cmdIfJust : Maybet-> (t->Cmde) ->Cmde
  Convert a value in a `Maybe` to a `Cmd e`.

Returns the empty command in case of a `Nothing`.

Totality: total
Visibility: export