Skip to content

SyntaxError: Invalid regular expression: /expression(/: Unterminated group #1697

Open
@viceice

Description

Describe the bug
Happy dom throws on a specific selector

To Reproduce
Steps to reproduce the behavior:

  1. create happy-dom window woth some html
  2. run document.querySelectorAll('[style*="expression("]')
  3. See error

Expected behavior
It should allow this valid selector

Screenshots
If applicable, add screenshots to help explain your problem.

Device:

  • OS: Windows
  • Browser: nodejs
  • Version v22.11.0

Additional context
happens when running angular tests with vitest v3

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions