Skip to content

Commit

Permalink
(example) update github-pages example (#52168)
Browse files Browse the repository at this point in the history
Removed `appDir: true` from experimental flag and code refactor.

Co-authored-by: Steven <229881+styfle@users.noreply.github.com>
  • Loading branch information
vinaykulk621 and styfle committed Aug 7, 2023
1 parent 1283270 commit c669c38
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion examples/github-pages/app/about/page.tsx
Expand Up @@ -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>
Expand Down
12 changes: 11 additions & 1 deletion examples/github-pages/app/layout.tsx
@@ -1,11 +1,21 @@
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,
}: {
children: React.ReactNode
}) {
return (
<html lang="en">
<body>{children}</body>
<body className={inter.className}>{children}</body>
</html>
)
}
6 changes: 1 addition & 5 deletions examples/github-pages/next.config.js
@@ -1,8 +1,4 @@
// @ts-check

/**
* @type {import('next').NextConfig}
**/
/** @type {import('next').NextConfig} */
const nextConfig = {
output: 'export',
basePath: '/gh-pages-test',
Expand Down

0 comments on commit c669c38

Please sign in to comment.