[theme-reviewers] Minified CSS?
Chip Bennett
chip at chipbennett.net
Thu Oct 4 18:56:53 UTC 2012
As far as I'm aware, it should be just fine, so long as you provide the
non-minified version in the Theme package.
Chip
On Thu, Oct 4, 2012 at 1:36 PM, Bruce Wampler <weavertheme at gmail.com> wrote:
> Just a question about providing Minified CSS files - and specifically the
> main style.css file (with the standard header still included, of course!)
>
> For my theme, if I could provide a minified style.css file, it would
> result in about 15K total size saving. In the context of an image, that
> isn't much, but it is also not a trivial amount. (And I really not looking
> for a debate on why I my theme has a 50K style file - it isn't that hard to
> do with lots of comments and responsive rules.)
>
> As per common practice, one would provide two versions of each minified
> file: style.css, and style.dev.css. In my tests, the minified file works
> exactly the same, and doesn't seem to give the Themes admin page any issues
> since the standard header is there.
>
> For my theme in particular, I see two advantages to a minified style.css:
>
> 1. It is smaller. (Some of us still have 2G mobile phone service, believe
> it or not, and even 15K can help on a slow phone connection.)
>
> 2. It would discourage users from editing style.css, which is generally a
> terrible idea - but especially for my theme. The designer either needs to
> use built-in options from the theme to add custom CSS, or build a child
> theme.
>
> Reasons not to allow:
> 1. Human unreadable - theme reviewer would have to trust the minified
> version is the same as the .dev full version. The .dev version or a browser
> developer tool can be used to examine the rules.
> 2. Most themes probably don't have 50K style files, so the savings would
> not usually be all that significant.
>
> I don't remember seeing this discussed before, and wondered if it is a
> permissible thing to do. I know themes and plugins commonly provide dev and
> minified version of .js files, seems .css isn't that much different.
>
> Bruce Wampler
> Weaver Theme
>
> _______________________________________________
> theme-reviewers mailing list
> theme-reviewers at lists.wordpress.org
> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wordpress.org/pipermail/theme-reviewers/attachments/20121004/da077f26/attachment.htm>
More information about the theme-reviewers
mailing list