If true, the controller value will be updated automatically if target
object is modified.
Carefull: heavy use may reduce performance
group.add('someProperty', target, { listen: true })
If true, the controller will not be editable
Display name of a controller, defaultly equal to property
.
group.add('someProperty', target, { name: 'Custom display name' })
property controlled in the target object
source object in which the property key is defined
Manually update controller value in the form if target
has changed
Delete the controller
Add a controller in the same Group
of current controller
Generated using TypeDoc
BaseController
is the common class used by all others controllers.How to use
Deal with events
Three kinds of events are emitted by all the controllers
input
: Trigger when aninput
event is trigger by anHTMLInputElement
change
: Trigger when anchange
event is trigger by anHTMLInputElement
update
: Trigger when a modification is made on the target property. It's the most common way to usedata-gui
Listen to event
Method one
Method two (using
web-component
andCustomEvent
)Remove listener
You can use either
off
orremoveEventListener
to do so.