How to remove pseudo-elements with CSS?

Spread the love

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.

Leave a Reply

Your email address will not be published. Required fields are marked *