Move application.tailwind.css to a dir ignored by propshaft#474
Merged
Conversation
61f3596 to
169e7f0
Compare
This file should not be included in the stylesheet link tags served to user agents. Fixes #470
169e7f0 to
31621ea
Compare
Member
Author
|
I'm not positive this is the best possible implementation of a fix, but I'm feeling a bit of time pressure and this is good enough to ship in a second release candidate. |
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.
This file should not be included in the stylesheet link tags served to user agents. But by default, Rails 8 apps add a tag for all CSS files under
app/assets(courtesy of a Propshaft feature handling a source named:all), and so this file is being included unintentionally.Going forward, in version 4.x of this gem (which pins to Tailwind v4), the installer will place the file into
app/assets/tailwind. The upgrader will move it fromapp/assets/stylesheetstoapp/assets/tailwind.And the gem's railtie adds
app/assets/tailwindtoconfig.assets.excluded_pathsto make sure it doesn't get served up by thestylesheet_link_tags :appcall in the application layout.This is being tested with both Rails 7.2 (without Propshaft) and Rails 8 (with Propshaft) and it looks good.
Fixes #470