Skip to content

Commit e489367

Browse files
author
Ethan Neff
committed
fix: removed redundant AppRegistry
1 parent aec60ac commit e489367

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

src/containers/App/index.tsx

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,7 @@
11
import * as React from "react";
2-
import { Platform, StyleSheet, Text, View, AppRegistry } from "react-native";
2+
import { Platform, StyleSheet, Text, View } from "react-native";
33
import Hello from "../../components/Hello";
44

5-
const instructions = Platform.select({
6-
android:
7-
"Double tap R on your keyboard to reload,\n" +
8-
"Shake or press menu button for dev menu",
9-
ios: "Press Cmd+R to reload,\n" + "Cmd+D or shake for dev menu"
10-
});
11-
12-
const App = () => (
13-
<View style={styles.container}>
14-
<Text style={styles.welcome}>Welcome to React Native!</Text>
15-
<Text style={styles.instructions}>To get started, edit App.js</Text>
16-
<Text style={styles.instructions}>{instructions}</Text>
17-
<Hello name="bob" enthusiasmLevel={1} />
18-
</View>
19-
);
20-
215
const styles = StyleSheet.create({
226
container: {
237
flex: 1,
@@ -37,6 +21,22 @@ const styles = StyleSheet.create({
3721
}
3822
});
3923

40-
AppRegistry.registerComponent("example", () => App);
24+
const instructions = Platform.select({
25+
android:
26+
"Double tap R on your keyboard to reload,\n" +
27+
"Shake or press menu button for dev menu",
28+
ios: "Press Cmd+R to reload,\n" + "Cmd+D or shake for dev menu"
29+
});
30+
31+
const App = () => (
32+
<View style={styles.container}>
33+
<Text style={styles.welcome}>Welcome to React Native!</Text>
34+
<Text style={styles.instructions}>
35+
To get started, edit ./src/containers/App/index.tsx
36+
</Text>
37+
<Text style={styles.instructions}>{instructions}</Text>
38+
<Hello name="Human" enthusiasmLevel={1} />
39+
</View>
40+
);
4141

4242
export default App;

0 commit comments

Comments
 (0)