this repo has no description
1import React from 'react'
2import { useSession, signIn, signOut } from "next-auth/react"
3import PurchasePage from '@/src/component/Purchase'
4import { Button } from '@mui/material'
5import Head from 'next/head'
6import styles from '@/styles/Home.module.css'
7
8const Index = () => {
9 const { data: session } = useSession()
10
11 return (
12 <>
13 <Head>
14 <title>Create Next App</title>
15 <meta name="description" content="Generated by create next app" />
16 <link rel="icon" href="/favicon.ico" />
17 </Head>
18 {
19 session && session.user ?
20 <PurchasePage /> :
21 <div className={styles.login_container}>
22 <div className={styles.login}>
23 <h1>
24 Donkenrush 2023
25 </h1>
26 <Button variant="contained" onClick={() => signIn()}>Sign in</Button>
27 </div>
28 </div>
29 }
30 </>
31 )
32}
33
34export default Index