package input import "github.com/vugu/vugu" type Button struct { AttrMap vugu.AttrMap SymbolSlot vugu.Builder `vugu:"data"` // Slot for the symbol. DefaultSlot vugu.Builder `vugu:"data"` Click ClickHandler // External handler that is called upon an event. } func (c *Button) HandleClick(event vugu.DOMEvent) { if c.Click != nil { c.Click.ClickHandle(ClickEvent{DOMEvent: event}) } }