Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • D digitec-wiki
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Digitec
  • digitec-wiki
  • Wiki
  • css and sass coding standards

css and sass coding standards · Changes

Page history
mmclin created page: css-and-sass-coding-standards authored Dec 11, 2013 by Mike McLin's avatar Mike McLin
Show whitespace changes
Inline Side-by-side
css-and-sass-coding-standards.markdown 0 → 100644
View page @ 1c2e01fc
CSS + Sass
==========
All of the following standards and practices on this page describe both CSS and Sass, unless otherwise noted.
Structure
---------
- Use 4-space indents, not tabs
- Add four blank lines between sections and one blank line between blocks in a section
- Each selector should be on its own line, ending in either a comma or an opening curly brace
- Property-value pairs can be on a single line, if there is only one pair for the selector, otherwise they should be on their own line
- Optionally, sets of property-value pairs can align vertically on the `:` chracter
- The closing brace should be left-aligned, using the same level of indentation as the opening selector
#### Wrong
```
.selector-1, .selector-2, .selector-3 {
background: #fff;
color: #000;
}
.selector-1 { background: #fff; color: #000; }
```
#### Good
```
.selector-1,
.selector-2,
.selector-3 {
background: #fff;
color: #000;
}
```
#### Best
```
.selector-1,
.selector-2,
.selector-3 {
background : #fff;
color : #000;
}
```
Clone repository
  • alpha beta testing
  • browser testing
  • camtasia licenses
  • code delivery processes
  • coding practices
  • css and sass coding standards
  • database schema standards
  • dependency management
  • development environments
  • digitec agile process
  • digitec gitlab styles
  • digitec software promises
  • digitec spec process
  • gitlab administration
  • gitlab issues tags
View All Pages