Repository navigation
Handle @plugin options blocks in Tailwind CSS compiler - #2187
Merged
Merged
Conversation
commit: |
webpro
approved these changes
Oct 22, 2026
webpro
left a comment
Member
There was a problem hiding this comment.
Thanks, Mantas! Nice catch, and good coverage with the braces in source() and the comment.
Member
|
π This pull request is included in v6.43.0. See Release 6.43.0 for release notes. Using Knip in a commercial project? Please consider becoming a sponsor. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A
@pluginoptions block with no;before its closing}makes the directive match run on to the next;in the file, so the directives after it (or the plugin itself) are missed. With@plugin "@tailwindcss/typography" {}, then@plugin "@tailwindcss/forms" { strategy: "class" }and@plugin "daisyui" {}, Knip reports@tailwindcss/formsanddaisyuias unused devDependencies. Tailwind accepts both forms and applies the options.A directive followed by an options block now ends at its
{; other directives still end at;.Extended the
compilers/tailwindfixture with an options block, a block without a trailing;and an empty block, and added a compiler test that also has braces in an@importparameter and a comment. On main the fixture test fails withfiles: 2anddevDependencies: 1; both tests pass now.pnpm run ciand the full test suite pass.