So after completing this course I've noticed a bug in our project. So if you remember we use the features folder to co-locate our components, our API and our hooks for specific entities. And one thing that's wrong here is that technically Tailwind has no access to this folder. I don't know if you remember but a couple of times throughout the course I've had some weird Tailwind bugs which I just assumed were cache errors. But what actually happened is inside of tailwind.config.ts.
As you can see inside of this content right here we can see the rules for where Tailwind is applied. And we can clearly notice that we never added the features folder. This is because usually in my tutorials I don't have to modify this simply because I put everything in the components or directly inside of the app folder. So there are two ways you can fix this. The first way would be to use a source directory but that would require a bunch of changes in your project.
So the easier thing to do is to simply copy one of the existing and rename this to features like this. So this will now include every single component that you can have inside which ends in TS or TSX file. Obviously if you're not using TypeScript go ahead and copy whatever you have which I assume would be .js and .jsx. So just by saving this I don't think anything will change in our project but I think we are definitely now going to have fewer Tailwind errors in our project. So to answer the question why exactly Did Tailwind even work in the features folder?
Well, I'm not exactly sure, but I have to assume it's something related to the Just-In-Time compiler and because we are importing a lot of files from the folders where Tailwind is supported. Right? So if you want to go ahead and try out some differences, I couldn't really find them. The way I realized this was when building a separate project and I added the features folder, and then I realized my Tailwind was simply not applied after deploying. So I assumed something was wrong and I figured out that my Tailwind config was completely missing the features folder right here.