Documentation
¶
Overview ¶
Package controller manages bindings with a model, and provides mutation methods
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
Controller handles the interaction of observable bindings between the model and the browser. It also handles action bindings with clickable objects.
func New ¶
New creates a new Controller instance given the web server's RPC service and a connection to the browser. namespace specifies the browser's binding namespace to use with this Controller's instance.
func Start ¶
func Start(ctx context.Context, ws *websocket.Conn) (c *Controller, done <-chan struct{}, err error)
Start starts server side rpc and creates a Controller. wait on the returned channel after creating your bindings.
func (*Controller) BindAction ¶
func (c *Controller) BindAction(element, action string, target func(string)) (err error)
func (*Controller) BindValues ¶
func (c *Controller) BindValues( name string, formID string, elements []string, source observable.Source, ) error
BindValues creates value bindings.
Click to show internal directories.
Click to hide internal directories.