Browse Source

Remove refresh button from example app

Janic Duplessis 4 years ago
parent
commit
c458e7a4c4
1 changed files with 4 additions and 11 deletions
  1. 4
    11
      example/App.tsx

+ 4
- 11
example/App.tsx View File

1
 import * as React from 'react';
1
 import * as React from 'react';
2
-import { View, Text, StatusBar, Button } from 'react-native';
2
+import { View, Text, StatusBar } from 'react-native';
3
 
3
 
4
 // import { SafeAreaProvider, useSafeArea } from 'react-native-safe-area-context'; in your app.
4
 // import { SafeAreaProvider, useSafeArea } from 'react-native-safe-area-context'; in your app.
5
 import {
5
 import {
48
 };
48
 };
49
 
49
 
50
 export default function App() {
50
 export default function App() {
51
-  const [refreshKey, setRefreshKey] = React.useState(1);
52
   return (
51
   return (
53
-    <View key={refreshKey} style={{ flex: 1 }}>
54
-      <SafeAreaProvider>
55
-        <Screen />
56
-        <Button
57
-          title="Refresh"
58
-          onPress={() => setRefreshKey(state => state + 1)}
59
-        />
60
-      </SafeAreaProvider>
61
-    </View>
52
+    <SafeAreaProvider>
53
+      <Screen />
54
+    </SafeAreaProvider>
62
   );
55
   );
63
 }
56
 }