Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> And yes, I abuse the slot attribute even when I'm only using CSS, without JS.

In CSS, how do you target <div slot="hero-blurb"> based on the "hero-blurb" slot?

div[slot="hero-blurb"]?





Yes, though often I’ll omit the tag, and just target [slot=“hero-blurb”]. Depends on the situation.



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

Search: