Skip to content

Remove auto-parenthesis logic for MediaQuery #15938

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

Open
paoloricciuti opened this issue May 16, 2025 · 2 comments
Open

Remove auto-parenthesis logic for MediaQuery #15938

paoloricciuti opened this issue May 16, 2025 · 2 comments

Comments

@paoloricciuti
Copy link
Member

Describe the bug

We added the auto-parenthesis logic before releasing it but it had multiple issues that we kinda had to patch with special cases and regexes. We can't remove it without a breaking change so opening this issue for 6.0

Reproduction

Logs

System Info

-

Severity

annoyance

@Rich-Harris
Copy link
Member

Do those issues still exist, or did #15937 fully fix them? Because I quite like the current behaviour

@paoloricciuti
Copy link
Member Author

I think the current implementation handles the issues...however it could be prone to bugs and would need to constantly adapt if new keywords are released for example. Also while not a huge deal since nobody in their right mind would tie a media query to user input the query that we have to use is subject to ReDoS.

I think we can discuss if we want to keep this behavior but better have a thoughtful discussion before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants