Issue Details (XML | Word | Printable)

Key: JAVASERVERFACES_SPEC_PUBLIC-1196
Type: New Feature New Feature
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: arjan tijms
Votes: 1
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
javaserverfaces-spec-public

CC-like conveniences for Facelet tags

Created: 02/Jun/13 03:30 PM   Updated: 08/Nov/13 09:15 PM
Component/s: Facelets/VDL
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

Tags: ease-of-use ease_of_development facelets tag taglib
Participants: arjan tijms and Ed Burns


 Description  « Hide

In JSF 2.x there are composite components and Facelets tags. A prime difference between these two is that composite components become a component themselves in the component tree, while Facelets tags cause their "child" components to be inserted but they themselves do not become part of the tree.

Both these two artifacts have their own unique use cases, and thus the newer composite component cannot totally replace the older Facelet tags.

However, composite components being the more modern variant have several ease of use features such as the ability for being auto-registering when put into the /resources folder and the definition of its attributes directly into the defining .xhtml file.

Since Facelets tags are still very useful in modern JSF programming, I'd like to request them being upgraded to support auto-registering and attribute definition in the .xhtml file as well.

E.g.

/resources/mytag.xhtml
<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets">
    
    <ui:attribute name="foo" />
    
    ...
</ui:composition>

The above would register a Facelets tag just like the following in a -taglib.xml would do:

<tag>
    <tag-name>mytag</tag-name>
    <source>tags/mytag.xhtml</source>
    <attribute>
        <name>foo</name>	
    </attribute>
</tag>


No work has yet been logged on this issue.