Replies: 1 comment 1 reply
-
|
Hi cell0901, The issue where Tailwind styles work inside your page.tsx but not on components imported from ui/src in a Turborepo setup usually comes down to how Tailwind processes your CSS and which files it scans for class names. Here are some common causes and fixes: Tailwind’s content (or purge) config missing ui/src Without this, Tailwind won’t generate styles for classes used in ui/src. PostCSS and Tailwind config shared or duplicated? CSS import scope Verify build and watch setup Summary: |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
So i initialized a turborepo with next app.
followed this guide to add tailwind to my next-app in /apps. https://tailwindcss.com/docs/installation/framework-guides/nextjs
now when i do styling directly inside the
page.tsxit works fine. but when i add components inside theui/srcfolder and import it to page.tsx the text and everything shows but the style inside theclassName""doesnt shows upAdditional information
Example
No response
Beta Was this translation helpful? Give feedback.
All reactions