RNative-Components
React Native -View- Component
I'm a huge fan of styled components and I use them extensively with React. I find the code much clearer without inline styles, and I can build some kind of UI Kit easily with it.
import { Text, SafeAreaView, StyleSheet,View } from 'react-native';
export default function App() {
return (
<SafeAreaView>
<View>
<View style={styles.box}></View>
<View style={styles.boxTwo}></View>
</View>
</SafeAreaView>
);
}
const styles = StyleSheet.create({
box:{
width:100,
height:100,
backgroundColor:"red"
},
boxTwo:{
width:100,
height:100,
backgroundColor:"cyan"
}
});