No description
Whether an explicitly listed directory is git ignored (and should bypass
the ignore rules as an external source) was decided by walking up from the
directory and letting the nearest `.gitignore` with a definitive answer
win. That's only half of git's precedence: a whitelist is unreachable when
a parent directory is excluded — git never descends into an excluded
directory, so re-include rules inside of it have no effect. With
.gitignore parent/
parent/.gitignore !child/
`@source "./parent/child"` stayed a regular auto source (the `!child/`
whitelist answered first), so the `.gitignore` files inside it kept
applying, even though git considers the whole tree ignored.
Decide exclusion the way git does instead: walk the path from the top
down, settling for every directory along the way whether it is excluded —
the first excluded directory makes everything below it ignored. Within a
single directory's decision the deepest `.gitignore` still wins, so
directories re-included by a deeper, reachable `!dir` pattern stay regular
auto sources. Both directions are now pinned by unit tests next to the
other promotion tests.
|
||
|---|---|---|
| .github | ||
| crates | ||
| integrations | ||
| packages | ||
| patches | ||
| playgrounds | ||
| scripts | ||
| .gitignore | ||
| .prettierignore | ||
| Cargo.lock | ||
| Cargo.toml | ||
| CHANGELOG.md | ||
| LICENSE | ||
| package.json | ||
| pnpm-lock.yaml | ||
| pnpm-workspace.yaml | ||
| README.md | ||
| rust-toolchain.toml | ||
| turbo.json | ||
| vitest.config.mts | ||
A utility-first CSS framework for rapidly building custom user interfaces.
Documentation
For full documentation, visit tailwindcss.com.
Community
For help, discussion about best practices, or feature ideas:
Discuss Tailwind CSS on GitHub
Contributing
If you're interested in contributing to Tailwind CSS, please read our contributing docs before submitting a pull request.