Uploaded image for project: 'RichFaces'
  1. RichFaces
  2. RF-12270

Allow RichFaces to bring new CSS/JS resources into the page after AJAX request

    Details

      Description

      Quoting the extract from official documentation (3.5 Restrictions):

      JSF 2 does not allow resources such as JavaScript or Cascading Style Sheets (CSS) to be added if the element requiring the resource is not initially present in the JSF tree. As such, components added to the tree via Ajax must have any required resources already loaded. In RichFaces, any components added to the JSF tree should have components with corresponding resources included on the main page initially. To facilitate this, components can use the rendered="false" setting to not be rendered on the page.

      Setting rendered="false" is OK when components are in the tree. However, if there are lots of components on a single view, for performance reasons some parts might be excluded by means of <c:if> or <c:choose> tags.
      That's at least what could be done in 3.3.3. It worked fine back then. However, the JSF2 AJAX mechanism does not support this feature. This makes usage of aforementioned tags impossible in some cases.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  tomasz.kurpios Tomasz Kurpios
                • Votes:
                  3 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                  Dates

                  • Created:
                    Updated:

                    Time Tracking

                    Estimated:
                    Original Estimate - 2 days
                    2d
                    Remaining:
                    Remaining Estimate - 2 days
                    2d
                    Logged:
                    Time Spent - Not Specified
                    Not Specified