Skip to content

[css-pseudo] purpose of focus-within? #1670

Closed
@jimmywarting

Description

@jimmywarting

Just discovered focus-within.
what dose it solve that :has() pseudo class can't fix?

eg:

form:has(:focus) { }
form:focus-within { }

I mostly think it's seems unnecessary to have focus-within, just adds more code, a yet another way of doing things

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions