All or Nothing

Avatar of Robin Rendle
Robin Rendle on

Jonathan Snook takes a look at the all property which can be used like this:

.element {
  all: initial;

The idea is that it should set all properties of an element to initial, removing all custom styling thus far applied. Essentially resetting the styles of any element so you can build up from scratch.

Unfortunately the inconsistencies between each browser make it difficult to recommend. If you could count on it being consistent, this is a powerful one-liner, alleviating some of motivation behind things like iframes, web components, or css modules.

Direct Link →