Files
ladybird/Libraries/LibWeb/CSS/SelectorEngine.cpp
Andreas Kling 04fd26a02b LibWeb: Fast-path simple descendant compound :has()
Teach :has() matching to recognize the common case of a single
descendant compound made only of tag and class selectors. This lets us
stay on the cheap per-element matcher instead of recursing through the
full relative-selector machinery for each candidate descendant.

Keep the optimization limited to that simple selector shape and fall
back to the generic matcher for everything else.
2026-04-20 13:20:41 +02:00

85 KiB