Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import React, { Component } from 'react';
- import { AppRegistry, Text, View } from 'react-native';
- class Greeting extends Component {
- render() {
- return (
- <Text>Hello {this.props.name}!</Text>
- );
- }
- }
- export default class LotsOfGreetings extends Component {
- render() {
- return (
- <View style={{alignItems: 'center'}}>
- <Greeting name='Rexxar' />
- <Greeting name='Jaina' />
- <Greeting name='Valeera' />
- </View>
- );
- }
- }
- // skip this line if using Create React Native App
- AppRegistry.registerComponent('AwesomeProject', () => LotsOfGreetings);
Add Comment
Please, Sign In to add comment