CSS Selector Level 4 » Subject of a selector with Child combinator

This selector is deprecated now and is no longer considered to make it into the final CSS level draft. This page is kept temporary as archive reference.

The subject of a selector with child combinator is normally the last compound selector itself but with this selector type it's possible to change this subject of the selector to the ! prefixed selector subject. The structure stays the same just the subject changes.

# Syntax

Copy
!subject > selector {
    /* declarations */
}

# Example

Copy
!ul > li {
    border: 1px solid green;
}

In this example there will be a green border around the ul (unordered list) instead the list items.

Try example in CodePen

# Browser support

Platform Chrome Firefox Safari Edge Internet Explorer Opera
Desktop No No No No No No
Mobile No No No No No No

Please wait a moment, the comments start loading now...
explorermozillachromesafariopera info external