Skip to content

Commit bda177a

Browse files
committed
Fixed issue with page title
1 parent 3aaec81 commit bda177a

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/components/layout.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,12 @@ interface PropsChildren {
1313
export default function Layout({ children }: PropsChildren) {
1414
const router = useRouter();
1515
const checkRouter = (router.pathname == "/");
16+
const title = cx(router.pathname != "/" ? router.pathname.slice(1).toLowerCase()+" - " : "", "Diego Silva");
1617

1718
return (
1819
<div className="h-screen w-full font-pontserrat">
1920
<Head>
20-
<title>{cx(router.pathname != "/" ? router.pathname.slice(1).toLowerCase()+" - " : "")}Diego Silva</title>
21+
<title>{title}</title>
2122
<link rel="icon" href="/favicon.png" />
2223
</Head>
2324
<NextProgress color="rgb(139 92 246)" delay={500} />

0 commit comments

Comments
 (0)