clerk sign in and sign up login setup
This commit is contained in:
committed by
GitHub
parent
640961eeec
commit
a5cabfe1a1
@@ -1,10 +1,24 @@
|
||||
import { SignedIn, SignedOut, useUser } from "@clerk/clerk-expo";
|
||||
import { Link } from "expo-router";
|
||||
import { Text } from "react-native";
|
||||
import { SafeAreaView } from "react-native-safe-area-context";
|
||||
|
||||
const Home = () => {
|
||||
const { user } = useUser();
|
||||
|
||||
return (
|
||||
<SafeAreaView>
|
||||
<Text>Home</Text>
|
||||
<SignedIn>
|
||||
<Text>Hello {user?.emailAddresses[0].emailAddress}</Text>
|
||||
</SignedIn>
|
||||
<SignedOut>
|
||||
<Link href="/sign-in">
|
||||
<Text>Sign In</Text>
|
||||
</Link>
|
||||
<Link href="/sign-up">
|
||||
<Text>Sign Up</Text>
|
||||
</Link>
|
||||
</SignedOut>
|
||||
</SafeAreaView>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user