Board index JavaServer Faces Extensions Design Discussions

Design Discussions

Community Driven Extensions Project

Post 18 May 2012, 10:46
tandraschko PrimeFaces Core Developer

Posts: 2001
Location: Bavaria, DE

ouputLabel sounds great. Could you also consider this issue: http://code.google.com/p/primefaces-ext ... ail?id=177 ?

ok, i will implement scriptCollector :)
Always Bet On Prime (+ Extensions)!

PrimeFaces Extensions: https://github.com/primefaces-extensions
OpenWebBeans: http://openwebbeans.apache.org/
DeltaSpike: http://deltaspike.apache.org/
Personal Blog: http://tandraschko.blogspot.de/

Post 18 May 2012, 13:29

Posts: 14916
Location: Cybertron

I've already done #177 ;)
PrimeFaces Lead

Post 18 May 2012, 13:54
tandraschko PrimeFaces Core Developer

Posts: 2001
Location: Bavaria, DE

Fast as always, cool!
Always Bet On Prime (+ Extensions)!

PrimeFaces Extensions: https://github.com/primefaces-extensions
OpenWebBeans: http://openwebbeans.apache.org/
DeltaSpike: http://deltaspike.apache.org/
Personal Blog: http://tandraschko.blogspot.de/

Post 18 May 2012, 13:54
Oleg User avatar
Expert Member

Posts: 3663
Location: Russia, Siberia => Germany, Black Forest
Last I'd like to promote the requiredLabel functionality to PrimeFaces, with required label indicator and styling when validation fails.

Yes, this promotion sounds good. Looking forward to requiredLabel functionality in PrimeFaces !

I also had a scriptCollector once when I was working on Tomahawk Client side validations, frankly I don't have time to do it, but if you guys try this at extensions project if you have time, we can discuss further.

I'm in favour of async. script loading and execution. Tested LabJS, HeadJS and other libs. For instance HeadJS brings good performance http://headjs.com/test/script.html (only 5 scripts are included) but with LabJS I had much better results. This feature is easy to implement in PrimeFaces / PrimeFaces Extensions and it can make scriptCollector useless because all scripts are always loaded / executed parallel (don't matter where you place them - in head or bottom). There are only 2-3 wait points, after jquery and primefaces core script. Most scripts are independent. This task is planned for 0.6. We should research yet if small scripts are loaded / executed faster than one big. I can imagine that there is a "golden mean" - not all scripts should be merged (what is true in PF Extensions). And sure, this feature should be enableable per configuration.
PrimeFaces 4.x, Mojarra 2.2.x, JBoss WildFly, WebSphere, Kubuntu 12.04, Windows 8.1, IntelliJ IDEA
PrimeFaces Cookbook: http://ova2.github.com/primefaces-cookbook/ PrimeFaces Extensions on GitHub: http://primefaces-extensions.github.com/

Post 18 May 2012, 14:12
tandraschko PrimeFaces Core Developer

Posts: 2001
Location: Bavaria, DE

Is this the task of scriptCollector?

I understand that the task is this:

before:

$(function() { PrimeFaces.CW 1..... });
... some html...
$(function() { PrimeFaces.CW 2..... });
... some html...
$(function() { PrimeFaces.CW 3..... });
... some html...
$(function() { PrimeFaces.CW 4..... });
... some html...
$(function() { PrimeFaces.CW 5..... });


after:

... some html...
$(function() {
PrimeFaces.CW 1.....
PrimeFaces.CW 2.....
PrimeFaces.CW 3.....
PrimeFaces.CW 4.....
PrimeFaces.CW 5.....
});
Always Bet On Prime (+ Extensions)!

PrimeFaces Extensions: https://github.com/primefaces-extensions
OpenWebBeans: http://openwebbeans.apache.org/
DeltaSpike: http://deltaspike.apache.org/
Personal Blog: http://tandraschko.blogspot.de/

Post 18 May 2012, 14:21
Oleg User avatar
Expert Member

Posts: 3663
Location: Russia, Siberia => Germany, Black Forest
Yes, this is the task. But not only that. All inline AND added to head scripts should be shifted to body (actually target="body" would be better but we don't have this).
PrimeFaces 4.x, Mojarra 2.2.x, JBoss WildFly, WebSphere, Kubuntu 12.04, Windows 8.1, IntelliJ IDEA
PrimeFaces Cookbook: http://ova2.github.com/primefaces-cookbook/ PrimeFaces Extensions on GitHub: http://primefaces-extensions.github.com/

Post 18 May 2012, 14:27
tandraschko PrimeFaces Core Developer

Posts: 2001
Location: Bavaria, DE

Moving scripts includes from head to body is really much faster?
I would only collect all inline scripts, no includes.
Always Bet On Prime (+ Extensions)!

PrimeFaces Extensions: https://github.com/primefaces-extensions
OpenWebBeans: http://openwebbeans.apache.org/
DeltaSpike: http://deltaspike.apache.org/
Personal Blog: http://tandraschko.blogspot.de/

Post 18 May 2012, 14:28
Oleg User avatar
Expert Member

Posts: 3663
Location: Russia, Siberia => Germany, Black Forest
Test this self with three links on top http://headjs.com/test/script.html There is a little difference. "The key to high performance is to load without blocking. ".

P.S. Back to p:outputLabel. I can remember we have position attribute for star (*) in pe:requiredLabel. This could be important for arabic countries.
Last edited by Oleg on 18 May 2012, 14:32, edited 1 time in total.
PrimeFaces 4.x, Mojarra 2.2.x, JBoss WildFly, WebSphere, Kubuntu 12.04, Windows 8.1, IntelliJ IDEA
PrimeFaces Cookbook: http://ova2.github.com/primefaces-cookbook/ PrimeFaces Extensions on GitHub: http://primefaces-extensions.github.com/

Post 18 May 2012, 14:31

Posts: 14916
Location: Cybertron

http://blog.primefaces.org/?p=1954

Regarding Arabic, I think there are more important things to do like rtl before positioning the required label.
PrimeFaces Lead

Post 19 May 2012, 10:26

Posts: 14916
Location: Cybertron

I've replaced the showcase themeswitcher on top right with your themeswitcher images;

http://www.primefaces.org/showcase-labs/ui/home.jsf

Looks awesome! Thanks!
PrimeFaces Lead

PreviousNext

Return to Extensions