DEV Community

Ajinkya Biyani
Ajinkya Biyani

Posted on

COOL THING WITH PSEUDO ELEMENT IN CSS. (:before)

CSS has a property called content. It can only be used with the pseudo elements :after and :before. It is written like a pseudo selector (with the colon), but it’s called a pseudo element because it’s not actually selecting anything that exists on the page but adding something new to the page. This is what it looks like:

Alt Text

With this CSS in place, we could have this HTML:

Alt Text

And the output would be like:

• Email address: chriscoyier@gmail.com

Top comments (0)