Skip to content

Add app/javascript as default compressor folder to make a lookup #79

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

Closed
andresgutgon opened this issue Oct 9, 2021 · 3 comments
Closed

Comments

@andresgutgon
Copy link
Contributor

What?

Hi, first of all thanks for the work done here!

I was playing with importmaps and this gem to feel how is not to have any build step : ). Looks really nice. To try I made a dummy Rails app and when I deployed I was missing in Tailwind purged CSS a couple of classes.

I realized that's because app/javascript folder is not taken into consideration when doing the purging.

Is explained in the README how to add that folder and I did and it works
image

But I was wondering if it doesn't makes sense to include Javascript as default place to be purged. I'm all in in the Less javascript is better : ) But still I think is really rare if at some point you're not going to do some javascript and add/remove some CSS class.

Sorry if this is not that the right place to discuss this.
My thought was that this error can be hard to find for people without experience and adding app/javascript can make their life easier

@dhh
Copy link
Member

dhh commented Oct 10, 2021

I think it's fair to include app/javascript by default as well 👍

@dixpac
Copy link
Contributor

dixpac commented Oct 10, 2021

I also think javascript/ should be included, we sure include it in all of our TW production apps for the same reasons you've described.

@andresgutgon
Copy link
Contributor Author

☝️ Done in that PR

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

No branches or pull requests

3 participants