feat: improve structure and error handling
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
export default function NotFound() {
|
||||
return (
|
||||
<main>
|
||||
<h2>Not Found</h2>
|
||||
<h1>Not found</h1>
|
||||
<p>Could not find requested resource</p>
|
||||
</main>
|
||||
)
|
||||
|
||||
20
app/[lang]/(preview)/preview/[contentType]/[uid]/page.tsx
Normal file
20
app/[lang]/(preview)/preview/[contentType]/[uid]/page.tsx
Normal file
@@ -0,0 +1,20 @@
|
||||
import {
|
||||
ContentTypeParams,
|
||||
LangParams,
|
||||
PageArgs,
|
||||
UIDParams,
|
||||
} from "@/types/params"
|
||||
|
||||
export default async function PreviewPage({
|
||||
params,
|
||||
searchParams,
|
||||
}: PageArgs<LangParams & ContentTypeParams & UIDParams, {}>) {
|
||||
return (
|
||||
<div>
|
||||
<p>
|
||||
Preview for {params.contentType}:{params.uid} in {params.lang} with
|
||||
params <pre>{JSON.stringify(searchParams, null, 2)}</pre> goes here
|
||||
</p>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
export default async function PreviewPage() {
|
||||
return null
|
||||
}
|
||||
Reference in New Issue
Block a user