ampproject / ampproject/worker-dom
Bug: querySelectorAll should not traverse into <template>
Open
- Dominant language
- TypeScript
- Stars
- 3.3k
- Forks
- 154
- PR merge metrics
- No merged PRs in 30d
Description
**summary**
The querySelector functions should stop traversing when a `` is found.
Currently, they match elems within a template.
Contributor guide
Research direction
Start by locating the querySelector and querySelectorAll implementations and their traversal tests. Reproduce the issue with an element inside a , then add a regression test showing that template descendants are not matched. Done means both query functions stop traversing at templates.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100