One proposed solution was
Code: Select all
<script>window.jQuery.ui || document.write('<!-- INCLUDEJS jquery.ui.js -->')</script>
One option, since we're getting an array of files, would be to check filenames. However, this is not practical because the file could be named just about anything.
A second, more drastic option, would be to simply do the same thing we do with jQuery itself and include the jQuery UI library into the core (while also providing the option for it to be loaded via CDN). An argument against this is that there is currently no core template that uses any jQuery UI functionality. However, I think that including the library even when it's not used by the core (yet) is a good idea because of two things:
1) There isn't as much potential for conflicts between extensions
2) If we decide to add some jQuery UI functionality into the style later, we don't have to go through adding the library to the core then.
Of course, since we don't use it already, I'd be okay with simply preventing multiple inclusions if there is a way to do so. Otherwise, I support adding the library to the package.
EDIT: jQuery UI has several components that can be selected when downloading. If we add it to the core, we need to select all available components so that we aren't unnecessarily limiting extension authors.