Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-40477

Convert YUI_config functions to a readable version

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.5
    • 2.6
    • JavaScript
    • MOODLE_25_STABLE
    • MOODLE_26_STABLE
    • Hide

      Note: You must check this with both jsrev = -1; and jsrev unset in your config file.

      Note: Have your JS console open for ALL testing here and be on the look out for any related errors

      • Generally check pages in Moodle
      • Confirm that there were no (new) JS errors on the page
      • Confirm that there all JS was correctly loaded by the YUI loader
      • Check the results of calls to theme/yui_combo.php
        • Confirm that the results had content
      • In the JS console run a few additional calls and check that the output in the Network console is appropriate:

        YUI().use('MODNAME');
        

        where modname is in:

      • moodle-core-notification
      • moodle-core-chooserdialogue
      • moodle-course-modchooser
      • moodle-calendar-eventmanager
      • moodle-calendar-eventmanager-skin
        And the following should be retrieved but have invalid content:
      • moodle-invalid-example
      • moodle-core-nomodule
      • moodle-core-notification-withsubmodule
      • moodle-core-notification-withsubmodule-skin
      Show
      Note: You must check this with both jsrev = -1; and jsrev unset in your config file. Note: Have your JS console open for ALL testing here and be on the look out for any related errors Generally check pages in Moodle Confirm that there were no (new) JS errors on the page Confirm that there all JS was correctly loaded by the YUI loader Check the results of calls to theme/yui_combo.php Confirm that the results had content In the JS console run a few additional calls and check that the output in the Network console is appropriate: YUI().use('MODNAME'); where modname is in: moodle-core-notification moodle-core-chooserdialogue moodle-course-modchooser moodle-calendar-eventmanager moodle-calendar-eventmanager-skin And the following should be retrieved but have invalid content: moodle-invalid-example moodle-core-nomodule moodle-core-notification-withsubmodule moodle-core-notification-withsubmodule-skin

    Description

      At present, we insert minified javascript into lib/outputrequirements.php for the YUI_config configFns.

      When we need to make modifications to these, they're painful to debug and entirely uncommented.

      It would make sense to:

      • pull these out into separate files;
      • unminify them;
      • comment them; and then
      • minify them using our js minification library instead caching them in MUC along the way.

      Attachments

        Issue Links

          Activity

            People

              dobedobedoh Andrew Lyons
              dobedobedoh Andrew Lyons
              Frédéric Massart Frédéric Massart
              Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
              Mark Nelson Mark Nelson
              David Woloszyn, Huong Nguyen, Jake Dallimore, Michael Hawkins, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                18/Nov/13