Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

querySelectorAll should return an array of Elements, not Nodes #441

Open
g105b opened this issue Jul 21, 2023 · 0 comments
Open

querySelectorAll should return an array of Elements, not Nodes #441

g105b opened this issue Jul 21, 2023 · 0 comments
Labels
bug Something isn't working as expected enhancement Improvement to existing functionality good first issue Good for newcomers
Projects

Comments

@g105b
Copy link
Member

g105b commented Jul 21, 2023

I'm not sure if this is accurate on MDN, but currently foreach($element->querySelectorAll("whatever") as $item) shows $item as a Node rather than an Element, so a lot of functionality is not being suggested by the IDE.

Maybe this can be solved by just type-hinting more accurately?

@g105b g105b added bug Something isn't working as expected enhancement Improvement to existing functionality good first issue Good for newcomers labels Jul 21, 2023
@g105b g105b added this to Backlog in Overview via automation Jul 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working as expected enhancement Improvement to existing functionality good first issue Good for newcomers
Projects
Overview
Backlog
Development

No branches or pull requests

1 participant