diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..d1bab07 --- /dev/null +++ b/.env.example @@ -0,0 +1 @@ +EXPO_PUBLIC_CLERK_PUBLISHABLE_KEY= \ No newline at end of file diff --git a/.gitignore b/.gitignore index ec8a36a..51a965f 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,13 @@ npm-debug.* *.mobileprovision *.orig.* web-build/ +.env # macOS .DS_Store + +# @generated expo-cli sync-2b81b286409207a5da26e14c78851eb30d8ccbdb +# The following patterns were generated by expo-cli + +expo-env.d.ts +# @end expo-cli \ No newline at end of file diff --git a/app/(auth)/_layout.tsx b/app/(auth)/_layout.tsx index 5a90d0b..791e8c7 100644 --- a/app/(auth)/_layout.tsx +++ b/app/(auth)/_layout.tsx @@ -5,7 +5,7 @@ export default function UnAuthenticatedLayout() { const { isSignedIn } = useAuth(); if (isSignedIn) { - return ; + return ; } return ; diff --git a/app/(auth)/sign-in.tsx b/app/(auth)/sign-in.tsx index d747e3f..ca4301b 100644 --- a/app/(auth)/sign-in.tsx +++ b/app/(auth)/sign-in.tsx @@ -1,7 +1,7 @@ -import { useSignIn } from "@clerk/clerk-expo"; -import { Link, Stack } from "expo-router"; -import { Text, TextInput, TouchableOpacity, View } from "react-native"; import React from "react"; +import { useSignIn } from "@clerk/clerk-expo"; +import { Link } from "expo-router"; +import { Text, TextInput, Button, View, Pressable } from "react-native"; export default function Page() { const { signIn, setActive, isLoaded } = useSignIn(); @@ -20,53 +20,35 @@ export default function Page() { password, }); + console.log(completeSignIn); + await setActive({ session: completeSignIn.createdSessionId }); } catch (err: any) {} }, [isLoaded, emailAddress, password]); return ( - setEmailAddress(emailAddress)} /> - - - Home - - - - setEmailAddress(emailAddress)} - /> - - - setPassword(password)} - /> - + setPassword(password)} + /> - - Sign in - +