6.2.1 Syntax - Reference Documentation
Authors: Andres Almiray
Version: 1.2.0
6.2.1 Syntax
These are the three options for writing a binding using thebind
node
- Long
bean1.prop1
to bean2.prop2
bind(source: bean1, sourceProperty: 'prop1', target: bean2, targetProperty: 'prop2')
- Contextual
bean1.prop1
to bean2.prop2
- Implicit source
bean(bean1, prop1: bind(target: bean2, targetProperty: 'prop2'))
- Implicit target
bean(bean2, prop2: bind(source: bean1, sourceProperty: 'prop1'))
sourceProperty:
or targetProperty:
can be omitted; the bind node's value will become the property name, in other wordsbean(bean1, prop1: bind('prop2', target: bean2))
- Short
bean(bean2, prop2: bind{ bean1.prop1 })