note on minified jquery.js and DEBUG mode #640

wants to merge 1 commit into


None yet

3 participants

evildmp commented Jan 11, 2013

#639 is more complicated than I first thought, so I have extracted one of the issues from it for this pull request, which I think will be simpler to deal with.



@timgraham timgraham commented on the diff Jan 13, 2013
@@ -1406,6 +1409,15 @@ If you require the jQuery library to be in the global namespace, for example
when using third-party jQuery plugins, or need a newer version of jQuery, you
will have to include your own copy of jQuery.
+Django provides both uncompressed and 'minified' versions of jQuery, as
+``jquery.js`` and ``jquery.min.js`` respectively.
+The ``BaseModelAdmin`` superclass has a ``media`` property that returns a list
timgraham Jan 13, 2013 Owner

I'd like to edit this paragraph slightly, does this look ok:

``ModelAdmin`` and ``InlineModelAdmin`` have a ``media`` property that returns
a list of ``Media`` objects which store paths to the JavaScript files for the
forms and/or formsets. If :setting:`DEBUG` is ``True`` it will return the
uncompressed versions of various JavaScript files, including ``jquery.js``; if
not, it will return the 'minified' versions.
evildmp Jan 13, 2013 Contributor

It looks fine; perhaps a comma after list of Media objects, but more importantly it's more accurate.

@timgraham timgraham closed this Jan 13, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment