chefhai/app/_layout.tsx

34 lines
978 B
TypeScript

import { AuthProvider } from "@/context/auth-context";
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
import { Stack } from "expo-router";
import { GestureHandlerRootView } from "react-native-gesture-handler";
import "../global.css";
const queryClient = new QueryClient();
export default function RootLayout() {
return (
<GestureHandlerRootView style={{ flex: 1 }}>
<QueryClientProvider client={queryClient}>
<AuthProvider>
<Stack screenOptions={{ headerShown: false }}>
<Stack.Screen
name="(tabs)"
options={{
headerShown: false,
}}
/>
<Stack.Screen
name="recipe-detail"
options={{
headerShown: false,
presentation: "card",
}}
/>
</Stack>
</AuthProvider>
</QueryClientProvider>
</GestureHandlerRootView>
);
}