This information is in draft form. Some parts are incomplete, or only present in point form. If you have comments or suggestions for improving this documentation, please contact ~firstname.lastname@example.org.
The Fluid framework's DOM Binder makes it easy for users to change the look of a component by providing an interface that allows the component developer to access DOM elements though selectors, without knowing anything about the particular mark-up in question.
Components access elements in the DOM through unique selector names. The component defines default values for the selectors, but implementors are free to override the defaults if they choose.
Component developers must declare the component's selectors in the defaults for the component:
The DOM Binder is automatically created and attached to the component when the view is initialized with
fluid.initView(). The DOM Binder's
location() function is bound to
that.locate() (see below for more information).
Using the DOM Binder
The component must use the DOM Binder for any access to the DOM elements that make up the component, using the
The selector name, as declared in the component's
Optional. The container element used to constrain the search for the element. Defaults to the component container.