-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Description
What version of Tailwind CSS are you using?
v4.0.0-beta.9
What build tool (or framework if it abstracts the build tool) are you using?
Vite v6.0.7
What version of Node.js are you using?
v23.2.0
What browser are you using?
Arc (Chromium)
What operating system are you using?
macOS
Reproduction URL
- Clone this repo: https://github.com/okkdev/tailwindcss4-class-detection-bug-repro/
- run
npm dev - notice that
bg-red-200is missing
Describe your issue
Tailwind doesn't detect the class inside this list [class("bg-red-200")] at https://github.com/okkdev/tailwindcss4-class-detection-bug-repro/blob/main/src/main.gleam#L33
It only works if there is a whitespace somewhere inside of the square braces.
As shown here: https://github.com/okkdev/tailwindcss4-class-detection-bug-repro/blob/main/src/main.gleam#L35
and here: https://github.com/okkdev/tailwindcss4-class-detection-bug-repro/blob/main/src/main.gleam#L38
It would be awesome if there was a way to customize the detection to support more languages like Gleam, instead of having to rely on the automatic detection.