JavaScript based linters and formatters can access Tailwind CSS data directly, since Tailwind CSS itself is written is exposed as JavaScript modules.
However, non-JS tools like Biome and Oxc don't have this advantage. To pull off CSS class sorting, some information is necessary (available utilities and variants, ordering-related information about them, possible values, etc).
My aim with this "spec" is to iterate on a possible format for this data, since the Tailwind CSS team is agreeable to the idea of providing this information through a stable API directly from Tailwind CSS. This way, the extracted information can be incorporated in these tools either by being built into them as a preset, or through config.
- Enable the creation of a preset.