1 Reply Latest reply on Nov 20, 2009 6:36 AM by Ilya Shaikovsky

    Minified richfaces css and js files

    Allan Topp Newbie

      I am trying to reduce the load size of my pages by reducing all the calls for richfaces js files into a single call. From reading the forums it appears this should be done with the following in the web.xml

      <context-param>
       <param-name>org.ajax4jsf.RESOURCE_URI_PREFIX</param-name>
       <param-value>rfRes</param-value>
       </context-param>
       <context-param>
       <param-name>org.richfaces.LoadStyleStrategy</param-name>
       <param-value>ALL</param-value>
       </context-param>
       <context-param>
       <param-name>org.richfaces.LoadScriptStrategy</param-name>
       <param-value>ALL</param-value>
       </context-param>
       <context-param>
       <param-name>org.ajax4jsf.COMPRESS_SCRIPT</param-name>
       <param-value>false</param-value>
       </context-param>


      and adding to the page header script resource tags for ui.js and framework.js

      However this doesnt seem to have an impact. When I go to a page containing multiple richfaces components it downloads the individual js files for each component. For example I see in Firebug it pulls back



      rfResorg/richfaces/renderkit/html/scripts/utils.js
      rfResorg/richfaces/renderkit/html/scripts/modalPanel.js
      /rfResorg/richfaces/renderkit/html/scripts/datascroller.js
      rfResscripts/ShuttleUtils.js
      rfResscripts/SelectItem.js
      


      And more. This is all running in a portal environment with PortletBridege 1.0.0CR2 so I am not sure if that impacts it or not.