{{#if (includes examples "ai")}} import "@/polyfills"; {{/if}} {{#if (eq api "trpc")}} import { queryClient } from "@/utils/trpc"; {{/if}} {{#if (eq api "orpc")}} import { queryClient } from "@/utils/orpc"; {{/if}} {{#if (eq backend "convex")}} import { ConvexProvider, ConvexReactClient } from "convex/react"; {{else}} {{#unless (eq api "none")}} import { QueryClientProvider } from "@tanstack/react-query"; {{/unless}} {{/if}} import { Stack } from "expo-router"; import { GestureHandlerRootView } from "react-native-gesture-handler"; import { useUnistyles } from "react-native-unistyles"; export const unstable_settings = { // Ensure that reloading on `/modal` keeps a back button present. initialRouteName: "(drawer)", }; {{#if (eq backend "convex")}} const convex = new ConvexReactClient(process.env.EXPO_PUBLIC_CONVEX_URL!, { unsavedChangesWarning: false, }); {{/if}} export default function RootLayout() { const { theme } = useUnistyles(); return ( {{#if (eq backend "convex")}} {{else}} {{#unless (eq api "none")}} {{else}} {{/unless}} {{/if}} ); }