This content originally appeared on Bram.us and was authored by Bramus!
Jim Nielsen set out to style a bunch of links that appeared before hr
elements. His solution? The :has()
selector.
p:has(+ hr) a:only-child {
}
This, again, proves that the :has()
selector is way more than just a parent selector.
This content originally appeared on Bram.us and was authored by Bramus!
Bramus! | Sciencx (2022-06-28T21:57:31+00:00) A Previous Sibling Selector. Retrieved from https://www.scien.cx/2022/06/28/a-previous-sibling-selector/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.