I'm running with Liferay 6.2 and JSF 2.2.12
I have two custom portlets (using Primefaces).
My portlets import Javascript resources using <h:head />.
Those portlets are displayed on the same page.
On my staging environment primefaces.js is included once in the rendered view :
<script src="https://example.com/group/my-site/url?p_p_id=portletone_WAR_portletone&...javax.faces.resource=primefaces.js...">
Why do I get two <script> in production environment :
<script src="https://example.com/group/my-site/url?p_p_id=portletone_WAR_portletone&...javax.faces.resource=primefaces.js...">
<script src="https://example.com/group/my-site/url?p_p_id=portlettwo_WAR_portlettwo&...javax.faces.resource=primefaces.js...">
(same observation with jquery.js)