Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS CSS naming convention, which is good??

  • This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #144517
    rams
    Participant

    Hi All CSS enthusiast here,

    most of the frameworks follows detailed naming for selectors, like
    jquery UI – ui-datepicker-buttonpane button

    i was thinking what if we abbreviate these names like

    ui-dtpcr-btnpne or like, to reduce the length and keep a readme file to elaborate those full names.

    any thought?

    cheers!
    -rams

    #144520
    Paulie_D
    Member

    For a small project that’s OK as long as you understand them. I would keep the actual details as comments inside the CSS stylesheet though rather than a separate file.

    Anyway, with proper minifying and compression long class names aren’t going to save you much anyway.

    #144573
    Josh Johnson
    Participant

    I use this method for CSS, works great for me. http://bem.info/

    #144578
    TheDoc
    Member

    I absolutely *hate* it when people use shortened names. It’s so difficult to properly read unless you’ve created them yourself.

    #144582
    Kitty Giraudel
    Participant

    You should avoid shortened names. What is obvious to you may not be for anyone else.

    I would go for BEM-like approach, anytime.

    #144636
    rams
    Participant

    Thanks all for the appropriate comments,

    I was kinda confuse but we learn everyday, right?

    Appreciating all thoughts,

    -rams

Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘CSS’ is closed to new topics and replies.