Skip to content

Instantly share code, notes, and snippets.

View ibrunotome's full-sized avatar
👨‍💻
Up and running...

Bruno Tomé ibrunotome

👨‍💻
Up and running...
View GitHub Profile
@alexanderbuhler
alexanderbuhler / README.md
Last active June 22, 2026 07:50
Tailwind v4 polyfill / browser compatibility configuration

This gist may be your full solution or just the starting point for making your Tailwind v4 projects backwards compatible.

What it does

  • Effectively getting browser support down to Chrome 99 (and basically everything supporting @layer)
  • Pre-compute oklab() functions
  • Pre-compute color-mix() functions (+ replace CSS vars inside them beforehand)
  • Remove advanced instructions (colorspace) from gradients
  • Provide support for nested CSS (used by dark mode or custom variants with &)
  • Transform translate, scale, rotate properties to their transform: ... notation
  • Add whitespace to var fallbacks var(--var,) > var(--var, ) to help older browsers understand