Skip to content

Media queries not working in Safari 16.4 #17197

Answered by adamwathan
aaronadamsCA asked this question in Help
Discussion options

You must be logged in to vote

Hey! What you're seeing is that CSS nesting isn't supported at all in Safari 16.4:

https://caniuse.com/css-nesting

We don't flatten nesting in development with Tailwind because we assume that developers are developing using recent browser version that does support nesting, but we do flatten nesting in production builds. We use Lightning CSS for that which introduced some overhead so we skip it in development.

Tailwind Play doesn't run Lightning CSS either so we can keep the website light/fast and not ship all the WASM necessary to the client.

Your example should work if you do a production build 👍 We're also exploring moving the nesting flattening into core instead of relying on Lightning…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@aaronadamsCA
Comment options

Answer selected by aaronadamsCA
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #17196 on March 14, 2025 15:48.