Guest User

Untitled

a guest
Jan 9th, 2023
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import { type NextPage } from "next";
  2. import Head from "next/head";
  3. import Link from "next/link";
  4. import { signIn, signOut, useSession } from "next-auth/react";
  5.  
  6. import { api } from "../utils/api";
  7.  
  8. const Home: NextPage = () => {
  9.   const { data: session } = useSession();
  10.   return (
  11.     <>
  12.       <Head>
  13.         <title>Create T3 App</title>
  14.         <meta name="description" content="Generated by create-t3-app" />
  15.         <link rel="icon" href="/favicon.ico" />
  16.       </Head>
  17.       <div>
  18.         <button onClick={() => signIn()}>Login</button>
  19.         {JSON.stringify(session)}
  20.       </div>
  21.     </>
  22.   );
  23. };
  24.  
  25. export default Home;
  26.  
Advertisement
Add Comment
Please, Sign In to add comment