[ALOY-143] Allow all elements to have "require" attribute
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | Medium |
Status | Closed |
Resolution | Invalid |
Resolution Date | 2012-08-18T20:44:18.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | XML |
Labels | n/a |
Reporter | Tony Lukasavage |
Assignee | Tony Lukasavage |
Created | 2012-07-30T09:03:06.000+0000 |
Updated | 2014-06-22T13:23:09.000+0000 |
Description
Right now only the Widget and View elements can have a "require" attribute. It would be nice if all elements could have this attribute. That way we can make use of the element name to do additional code validation at compile time. For example:
<TabGroup>
<View require="someTabView"/>
</TabGroup>
Right now we don't have a good way to verify that that element is in fact a Tab. We could inspect the view ahead of time, but that seems cumbersome and not readily apparent to the developer. If we instead allowed the element name to reflect the contained root element, it would be easy for developers to see what they are requiring, and we could make checks at compile time to confirm that it is valid:
<TabGroup>
<Tab require="someTabView"/>
</TabGroup>
require
attribute no longer exists