jsr372-experts@javaserverfaces-spec-public.java.net

[jsr372-experts] Re: [jsr372-experts mirror] Re: [1359-views] DISCUSSION

From: Hanspeter <hampidu_at_gmail.com>
Date: Tue, 10 Mar 2015 09:37:25 +0100

Hello.

I think it would be to restrictive and break backward compatibility if such
a /views folder/mapping is introduced in general.

The way how JSF handles resources and contracts folders let's it open to
the developer how to organize facelets as views, includes, templates and
composite components. All of these different type of facelets can be
replaced/overridden in a contract and that is how contracs where introduced
(as I understood it).

However, I also feel it would be good to prevent xhtml source exposure by
JSF standard configuration and in case path prefix mapping is used it would
also be nice to use/support extension-less view URL.

And it would also be possible to optionally configure/allow a folder name
to contain only top-level view facelets, probably placed into resources and
contracts folder to allow some scanning of the toplevel views. This might
come as an extension or be part of JSF standard - both would be ok for me.

Hope my 2cents contribute tp the discussion.

Regards
Hanspeter
Am 09.03.2015 21:12 schrieb "arjan tijms" <arjan.tijms_at_gmail.com>:

> Hi,
>
> On Mon, Mar 9, 2015 at 8:36 PM, Frank Caputo <frank_at_frankcaputo.de> wrote:
> > Will we deprecate the possibility to replace whole views in contracts?
> If not, I’m OK with it.
>
> I personally have not argued for that and it would be OK for me if
> that possibility remains. I do like to see it documented a bit better.
> There are at least 2 places in the spec that could at least "casually"
> mention that this is possible.
>
> The previous discussions about resource contracts did hint if I
> remember correctly that a more strict contract definition would be
> investigated. Currently it's just a directory with files. Any plans
> there?
>
> > I did not yet understand 100%, what will be in the views folder? Only
> views or templates or includes or simply all of them? If it is the latter,
> I’d propose to call it facelets.
>
> The proposal asked for only top-level views to be there. The idea was
> as analogy of sorts to /resources, which also doesn't contain all
> kinds of Facelets.
>
> Kind regards,
> Arjan
>