5

I found it from W3C. http://www.w3.org/TR/css3-content/#nesting

4.2.1. Nesting '::before' and '::after' pseudo-elements

The selector '::before::before' represents a pseudo-element contained at the start of a pseudo-element contained at the start of an element. For example, the following rules: div { content: 'A' } div::before { content: 'B'; } div::before::before { content: 'C'; } ...would result in the following rendering objects:

,-----------------------.
| ,---------.           |
| | ,---.   |           |
| | | C | B | A         |
| | `---'   |           |
| `---------'           |
`-----------------------'

But it was not work in Chrome 30. http://codepen.io/tychio/pen/pLDqm

So I just want to ask how can use after or before to nest.

Community
  • 1
  • 1
Tychio
  • 591
  • 1
  • 7
  • 20

1 Answers1

5

True, that module was proposed, but unfortunately not implemented by any browser.

So for now you can't do this.

Edit: Just found this post

Community
  • 1
  • 1
Danield
  • 121,619
  • 37
  • 226
  • 255