Replies: 3 comments
-
|
Shadcn/ui is not a normal component package. The new npm package called "shadcn" is only a CLI tool. Because of this setup, the CLI may insert extra CSS imports like: That is why the Switch component did not work until that CSS was included. This change is intentional and not an oversight. |
Beta Was this translation helpful? Give feedback.
-
|
Thank you for the reply @shafisma. It's only being added when running |
Beta Was this translation helpful? Give feedback.
-
|
So, This now behaves like a documentation gap, not a philosophy shift. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
<Switch/>component doesn't work without@import "shadcn/tailwind.css";. Manual installation doesn't mention that we need to add following toindex.cssIt’s unusual for shadcn to offload logic to an internal npm package. Is this an intentional change in philosophy, or an oversight?
Beta Was this translation helpful? Give feedback.
All reactions