Skip to content
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

Support @import "tailwindcss" using top-level index.css file #11205

Merged
merged 2 commits into from
May 10, 2023

Conversation

RobinMalfait
Copy link
Member

This PR adds an index.css file to the root of the package that contains the @tailwind directives for each of Tailwind's layers.

/* node_modules/tailwindcss/index.css */
@tailwind base;
@tailwind components;
@tailwind utilities;

If you have postcss-import configured in your project, this makes it possible to add Tailwind to your CSS using a simple @import instead of writing out the @tailwind directives yourself:

@import "tailwindcss";

@adamwathan adamwathan changed the title Allow to use @import "tailwindcss"; directly Support @import "tailwindcss" using top-level index.css file May 10, 2023
@RobinMalfait RobinMalfait merged commit d637f37 into master May 10, 2023
@RobinMalfait RobinMalfait deleted the feat/add-tailwindcss-import branch May 10, 2023 17:44
RobinMalfait added a commit that referenced this pull request May 12, 2023
)

* make `@import "tailwindcss"` work out of the box

* update changelog
brandonmcconnell pushed a commit to brandonmcconnell/tailwindcss that referenced this pull request May 13, 2023
…lwindlabs#11205)

* make `@import "tailwindcss"` work out of the box

* update changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant