Since when does document.querySelector("a:has(.b)") not work on Firefox? the docs suggest it should work and I really thought it did

enthusiast enthusiast
offsite reposts: @nex3-reposts
clips & pics: @nex3-moments
Cohost utilities:
header photo by me
Since when does document.querySelector("a:has(.b)") not work on Firefox? the docs suggest it should work and I really thought it did
It's working for me, on this page document.querySelector("p:has(code)") selects the <p> element around your post.
and if I add the classes then document.querySelector(".a:has(.b)") selects the same element
what's the specific code you're trying to use? what html do you expect it to select that it does not?
literally any :has() in a query selector call throws an "unsupported selector" exception
what the heck. i'm on 128.0.3. caniuse says it was supported starting in version 121 which is december 18 2023. if you're on a version before 121 then that could cause it? or if layout.css.has-selector.enabled is off in about:config