CSS Naming conventions

Naming conventions are no less important to a development team than code specification, which can be explicitly used by named classes or functions to avoid duplication

In daily development, communication is sometimes face-to-face, sometimes via email, and sometimes through shared rules or habits. Must emphasize the habit, habit can make a person become an excellent person, habit can also make a team to become a relatively efficient team, communication barrier-free team

Common id names:

Page structure

  • Container: the container
  • Header: header
  • Content: the content/container
  • Page body: main
  • Footer: the footer
  • Navigation: nav
  • Sidebar: the sidebar
  • Column: the column
  • The periphery of the page controls the overall layout width: Wrapper
  • Left right center: left right center

navigation

  • Navigation: nav
  • Main flight: MAINBAV
  • Subnavigation: Subnav
  • Top navigation: TopNav
  • Side navigation: sidebar
  • Left navigation: leftsidebar
  • Right navigation: Rightsidebar
  • Menu: a menu
  • Submenu: submenu
  • Title: the title
  • Abstract: the summary

function

  • Mark: logo
  • Advertising: banner
  • Login: login
  • Loginbar: loginbar
  • Registration: regsiter
  • Search: search
  • Functional area: Shop
  • Title: the title
  • Add: joinus
  • Status:
  • Button: BTN
  • Scrolling: scroll
  • TAB page: TAB
  • A list of articles
  • Prompt message: MSG
  • Current: current
  • Tip: Tips
  • Icon: icon
  • Note: note
  • Guide: guild.
  • Service: service
  • Hot, hot
  • News: news,
  • Download: download
  • Vote: vote
  • Partner: Partner
  • Link: Link
  • Copyright: copyright