26 Rules I Follow When Writing CSS To Make It Concise and Readable | by Arbaoui Mehdi | Sep, 2022 | Medium
Wed Sep 28 2022 20:22:56 GMT+0000 (Coordinated Universal Time)
Saved by
@dryadmedia
.declarationOrder {
/* Declarations */
$varName: #ccc;
/* Sass Inheritance */
@extend %a-placeholder;
@include silly-links;
// Content
content: "";
// Positioning
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 10;
// Box Model
display: block;
float: right;
width: 100rem;
height: 100rem;
padding: 10rem;
margin: 10rem;
// Typography
color: $varName;
font: normal 1rem "Helvetica", sans-serif;
line-height: 1.3;
text-align: center;
// Visual
background-color: $varName;
border-radius: 4px;
opacity: 1;
// Animation
transition: all 1s;
// Misc
user-select: none;
}
content_copyCOPY
https://arbaouimehdi.medium.com/26-rules-i-follow-when-writing-css-to-make-it-concise-and-readable-b56547a345b4
Comments