Skip to content

Instantly share code, notes, and snippets.

@rcanepa
Created July 18, 2017 21:02
Show Gist options
  • Save rcanepa/a507bd17b01ee1eb59cd15858a5e24e1 to your computer and use it in GitHub Desktop.
Save rcanepa/a507bd17b01ee1eb59cd15858a5e24e1 to your computer and use it in GitHub Desktop.
CSS debugging tricks
/* A trick to see the design's "skeleton" */
.someClass * {
background-color: rgba(100, 100, 100, 0.2);
}
/* Another trick */
*,
::before,
::after {
outline: 1px solid rgba(255,0,0,.5);
}
/* One more */
* { background-color: rgba(255,0,0,.2); }
* * { background-color: rgba(0,255,0,.2); }
* * * { background-color: rgba(0,0,255,.2); }
* * * * { background-color: rgba(255,0,255,.2); }
* * * * * { background-color: rgba(0,255,255,.2); }
* * * * * * { background-color: rgba(255,255,0,.2); }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment