Skip to content

Conversation

@thecrypticace
Copy link
Contributor

Fixes #1388

There's two problems here:

  • We consider any stylesheet with an @import a potential root. This includes compiled stylesheets that have URL imports to things like google fonts
  • We consider all "roots" graphs equally instead of prioritizing ones that import Tailwind CSS.
config: 'packages/web/app.css',
selectors: [
'{URL}/packages/shared/**',
'{URL}/packages/shared/ui.css',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these showing up indicates a problem with this approach. These show up because this is an imported file. this is generally fine

However, in this case it might be unexpected. Especially if packages/shared has its own Tailwind CSS config. It'll prefer packages/admin over packages/shared and that feels like a bug. 🤔

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I figured out a temporary solution that doesn't introduce potential issues like this. But it's kinda awful.

Will ship with it but it could use some improvement later.

@thecrypticace thecrypticace force-pushed the feat/improve-stylesheet-detection branch from dbccdfb to 73330db Compare June 5, 2025 19:02
@thecrypticace thecrypticace marked this pull request as ready for review June 5, 2025 19:05
@thecrypticace thecrypticace merged commit 5702ca6 into main Jun 5, 2025
12 checks passed
@thecrypticace thecrypticace deleted the feat/improve-stylesheet-detection branch June 5, 2025 19:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants