In the nextJS examples, specifically the example showing how to use TypeScript with NextJS, they don't use the NextPage type.
The file I'm talking about is here: https://github.com/vercel/next-learn-starter/blob/master/typescript-final/pages/posts/%5Bid%5D.tsx and the relevant code is this:
export default function Post({
postData
}: {
postData: {
title: string
date: string
contentHtml: string
}
}) {
return (...
I'd think that it could be written like this:
export default function Post : NextPage<Props> ({
postData
}: {
postData: {
title: string
date: string
contentHtml: string
}
}) {
return (...
or something similar.
My question is, I can't find any doc's in the NextJS site on using the imported interface NextPage, and specifically, the next team left it out of their documentation.
Should I be using NextPage?