Skip to content

[css-pseudo-4] Identity of Element.pseudo() return value #3607

Closed

Description

Image for: Description

@heycam wrote in #3541 (comment):


We need some wording about the identity of the object returned by pseudo(), for example whether it's required to be the same object each time you call it on an element with a given type.

Now that I think about it, if we do require that the same object is returned, what does it mean for the CSSPseudoElement object if we restyle the element and the pseudo goes away (and so null would be returned from another call to pseudo())? Is the CSSPseudoElement detached in some way? If we restyle again and the pseudo-element is recreated, does the old CSSPseudoElement remain functional? Might it be simpler to always return an object for a supported pseudo type, regardless of whether the pseudo currently exists?

Metadata

Image for: Metadata

Metadata

Image for: Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    Image for: Issue actions