Recently, while working on a website design project, I had the following media query in my codebase:
@media only screen and (max-width: 480px)
but after introducing Stylelint, it modified the query to:
@media only screen and (width <= 480px)
During a code review, a collaborator raised questions about this change. To quickly validate the modification, I turned to ChatGPT for assistance. Surprisingly, it pointed out that using relational operators like "<=" is not valid CSS as CSS doesn't support such comparisons. This made me question the validity of the change introduced by Stylelint.
I'm curious to know more about the differences between the two queries and whether the updated version is indeed valid. Any insights or explanations would be greatly appreciated! Thank you. :)