chore: use new components

This commit is contained in:
Sean Norwood 2022-04-03 20:04:28 +00:00
parent 73106fc74a
commit 2c4ab1bb42

View File

@ -1,12 +1,9 @@
import type { NextPage } from "next"; import type { NextPage } from "next";
import { signIn, signOut, useSession } from "next-auth/react"; import { signIn, signOut, useSession } from "next-auth/react";
import dynamic from "next/dynamic";
import Head from "next/head"; import Head from "next/head";
import { Suspense } from "react"; import { Suspense } from "react";
import { CustomHead } from "../components/CustomHead";
const DynamicHeader = dynamic(() => import("../components/Header"), { import { DynamicHeader } from "../components/Header";
suspense: true,
});
const SignInOutButton = ({ isSignedIn }: { isSignedIn: boolean }) => { const SignInOutButton = ({ isSignedIn }: { isSignedIn: boolean }) => {
if (isSignedIn) { if (isSignedIn) {
@ -22,15 +19,9 @@ const Home: NextPage = () => {
status, status,
}; };
console.log(status);
return ( return (
<> <>
<Head> <CustomHead />
<title>Tube Archivist</title>
<meta name="description" content="Generated by create next app" />
<link rel="icon" href="/favicon/favicon.ico" />
</Head>
<Suspense fallback={<h1>Loading</h1>}> <Suspense fallback={<h1>Loading</h1>}>
<DynamicHeader authData={authData} /> <DynamicHeader authData={authData} />