ui
ui copied to clipboard
tailwind.config.ts for typescript project
When we create nextapp with typescript then tailwind.config.ts file is generated but when shadcnui is initialised the tailwind.config.js file is produced which is conflicting with ts file
You need to mention the tailwind config at the time of initializing shadcn.
As mentioned in the image, when you are initializing shadcn, it asks you to locate tailwind config file, thats where you mention the tailwind.config.ts file.
I hope this helps!
@bibaswan7 it works, but It generates a TS file with CommonJS, not ESM.
I ran into this as well. It struggled to generate content in my ESM TS file, it ended up just shoving CJS content into the TS file which removed anything that I had in there.
I'm running into the same issue. After initializing shadcn, I'm no longer able to even use tailwind's px/py on non-shadcn components. Any fixes to this yet?
This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.