I have created a react-app using tailwind css, styled component. It’s working fine in development mode. But, after deploying in netlify, css styles are broken. I tried for a long time, but couldn’t solve the problem. Please help me.
my site link - https://jazzy-dusk-a6ae7d.netlify.app/
github repository: solo-chat/client at main · nazmulislam4/solo-chat · GitHub
Here is the develepement view.
@nazmulislam4 Try running the same Build command that you’re running on Netlify locally (npm run build
or react-scripts build
).
As it says, you can then serve your project statically with npx serve -s build
.
You’ll find that it looks the same as it does on Netlify, and thus that the issue is due to something that your project does differently during build than during develop.
Knowing this, you can then debug appropriately.