(example) update github-pages example (#52168)

Removed `appDir: true` from experimental flag and code refactor.

Co-authored-by: Steven <229881+styfle@users.noreply.github.com>
This commit is contained in:
vinay 2023-08-08 04:05:06 +05:30 committed by GitHub
parent 1283270a5b
commit c669c383a0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 7 deletions

View file

@ -3,7 +3,7 @@ import Link from 'next/link'
export default function About() {
return (
<>
<h1>About</h1>
<h1>About Page</h1>
<div>
Back to <Link href="/">Home</Link>
</div>

View file

@ -1,3 +1,13 @@
import type { Metadata } from 'next'
import { Inter } from 'next/font/google'
const inter = Inter({ subsets: ['latin'] })
export const metadata: Metadata = {
title: 'Next.js on GitHub Pages',
description: 'A Next.js web application on GitHub Pages',
}
export default function RootLayout({
children,
}: {
@ -5,7 +15,7 @@ export default function RootLayout({
}) {
return (
<html lang="en">
<body>{children}</body>
<body className={inter.className}>{children}</body>
</html>
)
}

View file

@ -1,8 +1,4 @@
// @ts-check
/**
* @type {import('next').NextConfig}
**/
/** @type {import('next').NextConfig} */
const nextConfig = {
output: 'export',
basePath: '/gh-pages-test',