11 Comments

  1. Terry Hale

    Good idea, about time! I would hope but not really expect that the idea of custom CSS within a theme’s option page is also a bad idea because it creates yet more stylesheets that kill performance. Mobile page load speed, anyone?

    Report

    • Justin Tadlock

      Such a feature would actually be faster than loading an extra stylesheet, provided the theme isn’t doing anything weird. Neither method is likely to be the bottleneck in performance.

      Report

  2. colinspColin

    Terrible idea. CSS changes are generally theme specific and refer to theme specific display. They should be part of the theme and not added extra bloat of yet another plugin. Yes the data should be properly sanitised BUT don’t make us add yet another plugin for something so simple as this.

    Report

    • Justin Tadlock

      It’s true that many CSS changes are theme specific. They’re also often specific to the site, regardless of the theme. I’ve been doing this long enough to see the various use cases. It just depends on what the user needs. Fortunately, plugins can and do handle both scenarios. Themes cannot.

      From a user standpoint this may seem “simple”, but it’s really not. Otherwise, we would’ve never had multiple discussions on it. There’s a lot of complexity to doing this and doing it right. What the new guidelines propose is to merely do it safely. We’re not forcing theme authors to do it right.

      Also, there is absolutely no difference in “bloat” between a theme doing it and a plugin doing it.

      I won’t even dive into the implications that such a feature would have on some multisite installs. The theme probably wouldn’t be allowed.

      The best and recommended method is to simply edit the style.css file (preferably via a child theme). Anyone comfortable enough to add code to their site should be comfortable enough to edit this file.

      Report

  3. Colin

    A good idea to ensure that the CSS is sanitised however a bad idea to insist on yet another plugin to do something that is theme related. Plugins are to add functionality. CSS is about display and this is what is handled by a theme and so CSS changes are theme specific and should be part of the theme and not add the additional bloat of yet another unnecessary plugin.

    Report

  4. Nick Haskins

    For those that don’t use Jetpack I recc Simple Custom CSS. We recc to our users and has always worked great.

    Report

  5. Alex Vasquez

    +1 for Jetpack’s custom css editor. Let’s you do Sass. Win!

    Report

  6. Steven Gliebe

    I can see why Jetpack has a custom CSS feature. Users of wordpress.com cannot create child themes. But that limitation does not exist on self-hosted sites.

    I understand there are different situations but, in general, the way I see it is that if someone is savvy enough to write custom CSS then they are savvy enough to create a basic child theme.

    If you have X amount of time available, why not use it to create a guide and example child theme rather than to develop an arguably unnecessary theme feature? It’s better to train people than to encouraging shortcuts.

    Report

Comments are closed.

%d bloggers like this: