aboutsummaryrefslogtreecommitdiff
path: root/App.tsx
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2024-10-05 23:27:42 +0530
committerAkshay Nair <phenax5@gmail.com>2024-10-05 23:27:42 +0530
commit59724a0947c25bfa3aa16bd4a97bd5449e87bbcd (patch)
treed70311e96d182d6d7c09f62433b40c6a3b83f169 /App.tsx
parentbc3487eac1f623c55658e57223c990414f30cba0 (diff)
downloaddaft-launcher-59724a0947c25bfa3aa16bd4a97bd5449e87bbcd.tar.gz
daft-launcher-59724a0947c25bfa3aa16bd4a97bd5449e87bbcd.zip
Refactor app view screens
Diffstat (limited to 'App.tsx')
-rw-r--r--App.tsx12
1 files changed, 3 insertions, 9 deletions
diff --git a/App.tsx b/App.tsx
index 08886a0..9bdcdcc 100644
--- a/App.tsx
+++ b/App.tsx
@@ -1,22 +1,16 @@
-import React, {Suspense, useEffect} from 'react';
-import {BackHandler, SafeAreaView, View} from 'react-native';
+import React, {Suspense} from 'react';
+import {SafeAreaView, View} from 'react-native';
import {GestureHandlerRootView} from 'react-native-gesture-handler';
import {AppView} from './src/AppView';
import {Provider as JotaiProvider} from 'jotai';
const App: React.FC = () => {
- // Disable back button
- useEffect(() => {
- const sub = BackHandler.addEventListener('hardwareBackPress', () => true);
- return () => sub.remove();
- }, []);
-
return (
<Suspense fallback={<View className="flex flex-1 bg-black" />}>
<JotaiProvider>
<GestureHandlerRootView>
<SafeAreaView className="flex flex-1 bg-black text-slate-200">
- <AppView />
+ <AppView key="view" />
</SafeAreaView>
</GestureHandlerRootView>
</JotaiProvider>