WordPress.org

Ready to get started?Download WordPress

Forums

CSS Bloat (8 posts)

  1. ursinus
    Member
    Posted 10 months ago #

    I'd like to start a fundamental ongoing discussion about the future of WordPress, since it is the dominant platform for site development in the world today. I think a big issue is bloat. As web developers we learn to code efficiently from the ground up, to make things fast and efficient and clean and orderly.

    Having done dozens of WordPress sites now and torn apart many themes to give people what they want, I am constantly amazed and dismayed by how astronomically bloated the CSS in most themes is. I know each theme varies according to the complexity of the design and feature set, and the coding style and ability of the author, etc. but the themes don't exist in a vacuum, and the fundamental architecture of WordPress certainly plays a significant role. In some themes just the comment-related styles alone are more verbose than all the styles that I might write for an entire static html site.

    Take a popular, simple looking theme like 2012. To be blunt, the CSS is an absolute abomination to someone who loves CSS and values clean, concise coding. That's not meant to hurt the author's feelings, but I think it's undeniable. CSS being my strong suit I have no trouble accomplishing whatever I need to with a theme like 2012. I can make it look like pretty much anything in a few hours, but it's still horribly, horribly bloated, and to a novice CSS person it must look like quantum physics.

    I'd like to see a future where WordPress cleans up its act considerably in terms of architecture and efficiency.

    One partial solution would be a dynamically linked system where function and corresponding styles are linked, users/developers are able to easily shut off parts of the WordPress feature set, and the style.css is revised and pared down dynamically, accordingly.

    WP would establish a system of describing and delineating the components that account for various functionality, theme authors would be able to hook chunks of CSS into each, and then end user (the person implementing the theme) would be able to reel in the CSS, and the overall efficiency of WordPress in general, by shutting down all of the parts of WP they don't want to use (without editing PHP), and the css would be pared down accordingly.

    Why not just ignore it? Well, it all has to be checked by the browser, but that's not really the point. I think the question is can WordPress ever be lean? I'd say in the current paradigm, no, never. Perhaps we need an entirely different version that focuses on speed, simplicity, and efficiency. I think so.

  2. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 10 months ago #

    Are you talking about the CSS for the administrator side of things?

    I am constantly amazed and dismayed by how astronomically bloated the CSS in most themes is

    I can't see how you link this with WordPress (core).

    To be blunt, the CSS is an absolute abomination to someone who loves CSS and values clean, concise coding

    Can you give an example of what you loathe?

  3. ursinus
    Member
    Posted 10 months ago #

    2012 is authored by WP. If the inventors of this CMS need 1,500 lines of CSS (by my count) to achieve such a fundamentally simple end product something is seriously wrong with the whole kit and kaboodle.

  4. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 10 months ago #

    2012 is authored by WP

    In your opinion, who are/is WordPress?

  5. ursinus
    Member
    Posted 10 months ago #

    I'm pretty literal, when I go here

    http://wordpress.org/themes/twentytwelve

    and it says - Author:wordpressdotorg, I take it at face value. Certainly seems more relevant to the issue at hand than if it said author: some guy that no one's ever heard of.

    That's not the point, the point is the CSS and overall architecture of WP is absurdly bloated and inefficient, and I don't see any indication that it will be improved. 1500 lines of CSS for this design? It's insane.

  6. Andrew Nevins
    Barrel Rider, Spam Zapper & Volunteer Moderator
    Posted 10 months ago #

    WordPress.org just represents the community of volunteers here. There's no one team that create the core application, then went on to create the Twenty Twelve theme. The authors of Twenty Twelve need not be the same as the developers of core WordPress.

    the point is the CSS and overall architecture of WP

    WordPress is the core application, it does not interfere with the CSS of themes.

    Why is the CSS bloated in the 2012 theme, in particular?

  7. ursinus
    Member
    Posted 10 months ago #

    if design is separate from content and function then how on Earth does one need 1500 lines of css to achieve such an utterly simple design? The css has been written to account for every possible scenario and option that WP provides, and you're stuck with all the crap regardless of what you use. Beyond that the CSS is just horribly written. I don't know, I guess this will go nowhere.

  8. WPyogi
    Volunteer Moderator
    Posted 10 months ago #

    So rewrite it if you don't like it. 1500 lines doesn't seem excessive to me either.

Reply

You must log in to post.

About this Topic

Tags

No tags yet.