'What is the difference between CSS selectors: element element( div p) vs element>element (div > p)? [duplicate]
I'm wondering about CSS selectors. Especially about this one: "div p" vs "div > p"
Solution 1:[1]
div p: all elements <p> inside <div> (including deeply nested elements)
div > p: all elements <p> which are direct children of <div>
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Rashad Saleh |
