We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm having an error in the post. I do not know if this is the version, but I didn't find a solution
The text was updated successfully, but these errors were encountered:
Hi I found a solution instead of this :
export default function Home({ posts }) {
do this
export default function Home({ posts } : any ) {
its to do with typescript. it always needs a definition type for every parameter
Sorry, something went wrong.
I think the issue is in getStaticProps() function. It should be setting "posts" as a const and then point props to posts. Please see below.
export async function getStaticProps() { const posts = (await getPosts()) || []; return { props: { posts } } }
No branches or pull requests
I'm having an error in the post. I do not know if this is the version, but I didn't find a solution
The text was updated successfully, but these errors were encountered: