Hacker News new | past | comments | ask | show | jobs | submit login

:has doesn't exist but you can do [].map.call(document.querySelectorAll("a img[src$='.gif']"), (e)=>e.closest("a")).filter(e=>e)



:has certainly does exist, but only in Safari. Hopefully Chrome and Firefox will catch up soon.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: