Repository for mobile application
-
Open terminal
npm i
-
Run the expo
run all
npm run start
only run in android
npm run android
only run in IOS
npm run ios
-
Open new terminal and run
npm run dev:tailwind
-
Go to PlayStore
Install app Expo or in this link
-
Scan QR Code in Expo or input the URL
This project use tailwind-rn from this link. Example:
import React from 'react';
import {SafeAreaView, View, Text} from 'react-native';
// add this import
import {useTailwind} from 'tailwind-rn';
const Hello = () => {
// also add this import
const tw = useTailwind();
return (
<SafeAreaView style={tw('h-full')}>
<View style={tw('pt-12 items-center')}>
<View style={tw('bg-blue-200 px-3 py-1 rounded-full')}>
<Text style={tw('text-blue-800 font-semibold')}>
Hello Tailwind
</Text>
</View>
</View>
</SafeAreaView>
);
};
export default Hello;
Notes : If during development, Tailwind CSS doesn't change or there are other issues related to CSS, perform a program rerun.