-
Improvement
-
Resolution: Fixed
-
Minor
-
2.0
-
None
-
MOODLE_20_STABLE
-
MOODLE_20_STABLE
MDL-22920 added support for easily loading custom YUI modules (aka Moodle YUI modules) via the new yui_module function. This function causes these modules to get loaded via yui_combo.php (regardless of the useexternalyui or yuicomboloading settings).
Currently, yui_combo.php does not support caching or revisions. Originally this wasn't necessary as YUI and YUI Galleries (the only JS previously loaded by yui_combo) had their own versioning. Moodle YUI modules need to be versioned so they can be cached effectively and still updated when purging caches.
The attached patch adds support for including $CFG->jsrev in the yui_combo URLs for Moodle YUI modules. The $CFG->cachejs setting is also supported.
I did not add cachejs or jsrev support to YUI modules as it has its own built in versioning. Similarly I didn't modify YUI Galleries as yui_module already supports gallery versions. This means that if cachejs is off, YUI modules and YUI Galleries will still be far-future cached. Only Moodle YUI modules will not be cached if cachejs is off. I think this is what should happen because YUI modules should only be changed upstream.
Please see the forum post: http://moodle.org/mod/forum/discuss.php?d=154359
- has a non-specific relationship to
-
MDL-22920 We need a method to easily add + require Moodle YUI modules like we do with YUI gallery
-
- Closed
-