tailwind class sm:max-w-xl not working but it is exist in tailwindcss
i can use sm:max-w-sm and sm:max-w-sm
but other class exists in tailwindcss notworking like:
sm:max-w-xl
sm:max-w-2xl
4 Replies
You will need to setup a custom theme if you need to use classes that are not part of filament. https://filamentphp.com/docs/3.x/panels/themes#creating-a-custom-theme
but sm:max-w-xl is a default class in tailwindcss, filament just use some class of tailwindcss. and if need more i need to setup a custom theme. yes?
Yes. When you run a production build of tailwind it purges unused classes to keep the file size as small as possible.
So just because it has classes available they are only available to be used for the build. It doesn’t mean they will be available in the final css file that gets built.
That’s just how tailwind works. 🙂 they have some good information about it on their site.
thank you🙂