| ▲ | dleeftink 18 hours ago | |||||||
Good use case for @container, @scope and :has(), where you forgo class definitions and use --custom-properties on the parent scope/container which are inherited downwards based on the existence of a scoped DOM pattern/container query, or 'upwards' by using a :has(child-selector) on the parent. Although be sure to avoid too many :has(:nth-child(n of complex selector)) in case of frequent DOM updates. | ||||||||
| ▲ | MarcelOlsz 15 hours ago | parent [-] | |||||||
Backend developers of HN downvoting this smh. | ||||||||
| ||||||||