Overview
The component config is a Javascript dictionary that contains all the information necessary to construct and configure a component.
Config Properties
Information within a config is used to construct a component. The key associated with each piece of information is dictated by convention. Some of the information is used by the platform when managing the component. In particular, the following properties are used by the platform.
- children (optional) - if children is present, it should be an array. This array should be present if the component acts as a container, i.e. it can contain other components as children. This is usually the case for components that are visual containers that contain other components.
- directives (optional) - the directives property specifies directives to the platform on how to treat the component. For example, if the component should not be deletable by the user, this can be specified in the directives object.
- script (required) - a string that indicates the URL of the javascript library that contains the constructor for the component
- wrappers
The config will most likely need to store other information, such as style information, that it used when it is inserted into a workspace or blog. There are two config properties that are reserved for saving component specific information.
- body - reserved for use by the component designer to save information about the component