Sometimes, we want to remove pseudo-elements with CSS.
In this article, we’ll look at how to remove pseudo-elements with CSS.
How to remove pseudo-elements with CSS?
To remove pseudo-elements with CSS, we set the content
property.
For instance, we write
p:after {
content: none;
}
to set content
to none
to remove the after pseudo-element after the p element.
Conclusion
To remove pseudo-elements with CSS, we set the content
property.