Wishing for more LESS in CSS

All of the themes I've been looking at use common CSS. I don't see any usage of LESS to generate the CSS. Hardcoding CSS into a theme seems to me to be as primitive as hard-coding a website itself without the use of a CMS or framework. Why don't more theme developers build their CSS with LESS or similar tools?
For example, why hardcode colors and their various hues throughout a stylesheet when a single color reference up-top can be changed to modify the entire site? And in plugins that include CSS (was just looking at Q&A from WPMUDEV) why hardcode the width of text fields in-line in CSS when a high level variable setting would be more efficient for later changes?

This is all subject to personal preferences about whether to use tools and which to use, and there are many levels of development expertise. I'm just surprised that this concept hasn't become a defacto part of the WP culture, like the template hierarchy, hooks, etc.

My personal frustration with this is that I might like a theme but not the chaos in the .css files. I can LESSify the CSS into a child theme, but when the parent theme is updated, reconciling the author's new CSS with the generated CSS takes a LOT of time - in essence, this operation creates a permanent fork of the theme and precludes updates.

Of course, some plugin/theme developers could be using LESS or SASS or something else to produce their CSS, and just not including those source files in their packages. But my guess is that this is not the case.

Thanks.

  • Rupok

    Hi Tony,

    I totally agree with you. That is the reason LESS was invented/created and all plugins and themes should have LESS generated CSS. I've seen couple of third party WordPress themes using LESS. You can modify the LESS file and compile from theme Options page. So when you need to change something, just update the LESS file and recompile. The change will be deployed in all over you site without any issue.

    You said "My personal frustration with this is that I might like a theme but not the chaos in the .css files" and I totally understand this. It totally makes sense. However, we can keep our fingers crossed that more devs provides LESS support in their theme.

    If you want to discuss this with our thousands of other members, I can move your threads to our Members' Forum. Please confirm if you want me to move. Other users may come up with some surprising ideas.

    Have a nice day. Cheers!
    Rupok

  • Tony G

    Rupok - Sincere thanks for your thorough response.

    Looking back I see this wasn't phrased as a support question to be answered or problem to be solved. So it does seem appropriate to move it to a member discussion area, reducing the clutter presented to WPMUDEV Support folks and your developers.

    However, moving to the Members forum takes a general purpose discussion, already accessible to all members AND the public, and cuts the audience to just the paid member audience. I value both audiences and feel the members add value, not that they/we are the value. I could have posted this inquiry in any WP forum but I picked this one because of the added value.

    Sure, we can move this to Members, but consider the CSS files in WPMUDEV plugins and themes are all hardcoded CSS, no LESS. So the problem is as prevalent here as it is everywhere else, and I suspect that if this were posted in the Members forum that your developers there might not see it as they would here.

    So ... your call. :slight_smile:

  • Kasia Swiderska

    Hello Tony,

    Sure, we can move this to Members, but consider the CSS files in WPMUDEV plugins and themes are all hardcoded CSS, no LESS.

    If you take a closer look on Upfront framework you will not, indeed, find LESS, but you will find SASS. So our themes are using CSS processor.
    Same goes for Hustle plugin. SASS will be also used in new CoursePress.
    Yes, our older plugins are not using benefits of SASS or LESS, but new ones are.

    So the problem is as prevalent here as it is everywhere else, and I suspect that if this were posted in the Members forum that your developers there might not see it as they would here.

    Our developers are reading quite often members forum - also support staff monitor it to look for new ideas, or interesting feedback (and we show that to our devs).

    And you will get more feedback on member forum from members than here - for some reason members are more likely to share their opinions there and not on support forum.

    kind regards,
    Kasia

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.