Here is a simple example of a React Native program that displays a "Hello, World!" message.
For run :
- For Android ( command : react-native run-android )
- For iOS ( command : react-native run-ios )
import React from 'react';
import { View, Text, StyleSheet } from 'react-native';
const App = () => {
return (
<View style={styles.container}>
<Text>Hello, World!</Text>
</View>
);
};
const styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
},
});
export default App;
© www.thecoderjob.com. All Rights Reserved. Designed by HTML Codex