tailwindcss/packages
Robin Malfait 0f6f7d480f
Ensure --value(…) is required in functional @utility definitions (#20005)
While working on #19989, I noticed that `--value(…)` inside functional
`@utility` definitions is not required right now.

That means that the following CSS is valid:
```css
@utility foo-* {
  color: red;
}
```

But this doesn't really makes sense, because this now accepts a value
and `foo-a`, `foo-b` and `foo-c` would generate the following CSS:
```css
.foo-a {
  color: red;
}
.foo-b {
  color: red;
}
.foo-c {
  color: red;
}
```
The `a`, `b`, and `c` are not doing anything here apart from making your
CSS bigger. So this is very likely an actual bug that you forgot to use
`--value(…)`.

Additionally, if a `--value(…)` was used, but it didn't resolve
anything, then we already properly discared the candidate.

## Test plan

1. Add test to ensure `--value(…)` is required in functional `@utility`
definitions
2. Existing tests pass
2026-05-04 16:44:28 +02:00
..
@tailwindcss-browser Bump dependencies (#19957) 2026-04-24 21:21:12 +02:00
@tailwindcss-cli Update enhanced-resolve 5.20.1 → 5.21.0 (minor) (#19998) 2026-05-01 11:29:19 +00:00
@tailwindcss-node Update enhanced-resolve 5.20.1 → 5.21.0 (minor) (#19998) 2026-05-01 11:29:19 +00:00
@tailwindcss-postcss Improve codebase quality (#19999) 2026-04-30 23:32:37 +02:00
@tailwindcss-standalone Update enhanced-resolve 5.20.1 → 5.21.0 (minor) (#19998) 2026-05-01 11:29:19 +00:00
@tailwindcss-upgrade Update enhanced-resolve 5.20.1 → 5.21.0 (minor) (#19998) 2026-05-01 11:29:19 +00:00
@tailwindcss-vite docs: fix various typos in comments and documentation (#19878) 2026-04-29 13:28:39 +00:00
@tailwindcss-webpack Bump dependencies (#19957) 2026-04-24 21:21:12 +02:00
internal-example-plugin Prefix internal modules with internal-* (#14074) 2024-07-29 10:58:07 -04:00
tailwindcss Ensure --value(…) is required in functional @utility definitions (#20005) 2026-05-04 16:44:28 +02:00
tsconfig.base.json Improve debug logs (#15303) 2024-12-11 15:27:20 +01:00