obytes / react-native-template-obytes

📱 A template for your next React Native project: Expo, PNPM, TypeScript, TailwindCSS, Husky, EAS, GitHub Actions, Env Vars, expo-router, react-query, react-hook-form.
https://starter.obytes.com
MIT License
2.19k stars 321 forks source link

The correct way to use tailwind #303

Closed lukenvn closed 5 months ago

lukenvn commented 5 months ago

Summary:

Hello guys, firstly thank you guys very much for your hard working, I'm new in the world of mobile development and your project help me a lot. Everything seems work well for me except the using of tailwind css class.

Steps to reproduce:

When I try to use a class in tailwind like : flex, flex-row, ... I noticed that some class works some dont. the classes that can work are the classes that defined inside global.css file. So If I want the class work, I have to define the class in global.css So my question (maybe stupid but I just want to make sure I'm not losing your awesome feature) is, Is it really that every time i want a class from tailwind I have to define it in global.css (copy it from tailwind source) or there is some hidden command/way that can help me to make the class work automatically?

Thank you guys in advance.

yjose commented 5 months ago

Hello @lukenvn , Tailwind should work the same as the web with Native Wind. You don't need to add classes explicitly to global.css