-
-
Notifications
You must be signed in to change notification settings - Fork 177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(PostCSS plugin): Add postcss
to used dependencies when using PostCSS with Tailwind CSS
#764
Conversation
|
Name | Link |
---|---|
🔨 Latest commit | 3cd136f |
commit:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @taro-28! Appreciated. I do have a question, though.
const resolve: Resolve<PostCSSConfig> = async (options, config) => { | ||
for (const plugin of await resolveConfig(options, config)) { | ||
// Because postcss is not included in peerDependencies of tailwindcss | ||
if (plugin === 'tailwindcss') return ['postcss']; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the reason for not adding a check for tailwindcss
in config.plugins
to the resolveConfig
function directly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I misunderstood the implementation policy🙏
FIxed!
03a7583
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, there was a mistake.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry taro. Is there anything in the documentation or code that could have prevented this? Maybe we can improve it for the next contributor.
Thanks for the fix!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, there was a mistake.
Re-fixed!
Sorry taro. Is there anything in the documentation or code that could have prevented this? Maybe we can improve it for the next contributor.
I re-read the documentation again, and it succinctly describes how to use resolveConfig
, so I thought it was fine as it is.
My misunderstanding was due to overcomplicating the issue, as it was a slightly exceptional modification, such as adding the plugin's dependency itself (postcss).
7d649cc
to
03a7583
Compare
03a7583
to
d56b911
Compare
Co-authored-by: Lars Kappert <[email protected]>
a889af7
to
4db3279
Compare
Thank you! 🙏 |
🚀 This pull request is included in v5.27.3. See Release 5.27.3 for release notes. Using Knip in a commercial project? Please consider becoming a sponsor. |
Closes #762