[theme-reviewers] Enqueue scripts from CDN

Otto otto at ottodestruct.com
Thu Aug 8 03:43:34 UTC 2013


On Wed, Aug 7, 2013 at 10:29 PM, Matt Beall <mbeall at starverte.com> wrote:
> So a theme shouldn't enqueue a CDN? I don't understand the reasoning behind
> this, but I am also wondering because my theme enqueues a CDN of Bootstrap.
> CDNs solve a lot of licensing issues and also decrease the size of a theme
> package. But if we shouldn't use CDNs, please let me know.

Couple points:

1. We don't allow it in the WordPress.org theme repository because it
causes problems for people trying to use the theme. All JS and CSS
must be packaged in the theme, except for special cases like Google
Fonts and similar*.

2. It doesn't get around any licensing issues, because if the theme is
including or using *anything* that is not GPL-Compatible, then it is
not allowed to be listed on WordPress.org, period.

So bottom line, a theme in the WordPress.org repository *cannot*
include a file from a CDN. This is a requirement, not a
recommendation.

-Otto

* Fonts are not generally "required" for a theme, and themes will
generally work fine because they can use a fallback font. While it is
preferable to include the font in the theme too, various technical
reasons make that exceedingly difficult. Services like Google Fonts
and Typekit and other webfont providers solve cross-browser
compatibility issues in ways better than theme authors usually can.


More information about the theme-reviewers mailing list