Uploaded image for project: 'Tapestry 5'
  1. Tapestry 5
  2. TAP5-1155

JavaScript initialization inside the partial page render Ajax response should be unquoted

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.2.0
    • Fix Version/s: 5.2.0
    • Component/s: tapestry-core
    • Labels:
      None

      Description

      Currently, all the JS in an Ajax partial page render update comes inside the "script" key, as a long string. This is inefficient, since so many characters and quotes need to be escaped, and it is also harder to read and debug (especially since pretty printing is turned off, since pretty printing inside a string is no more readable that not).

      Instead, the calls to Tapestry.init() can be handled differently in an Ajax response, and encoded in a new key, "inits", an array of Tapestry.init() parameters (multiple calls to init because of the scheduling: early, normal, late).

        Attachments

          Activity

            People

            • Assignee:
              hlship Howard M. Lewis Ship
              Reporter:
              hlship Howard M. Lewis Ship
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: