Skip to content

Instantly share code, notes, and snippets.

@Pranit-Harekar
Last active December 25, 2017 03:22
Show Gist options
  • Save Pranit-Harekar/931ef83be03fa9ef749d9b360ce1fb91 to your computer and use it in GitHub Desktop.
Save Pranit-Harekar/931ef83be03fa9ef749d9b360ce1fb91 to your computer and use it in GitHub Desktop.
Demo TypeScript Setup
import * as React from "react";
import { StyleSheet, Text, View } from "react-native";
export default class App extends React.Component {
render() {
return (
<View style={styles.container}>
<Text style={styles.welcome}>Welcome to React Native with TypeScript!</Text>
</View>
);
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: "center",
alignItems: "center",
backgroundColor: "#F5FCFF"
},
welcome: {
fontSize: 20,
textAlign: "center",
margin: 10
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment