Need help
Unanswered
Cape lion posted this in #help-forum
Cape lionOP
Anyone has seen this error message before?
My getServerSideProps:
⨯ Error: Additional keys were returned from `getServerSideProps`. Keys that need to be moved: revalidate.My getServerSideProps:
export const getServerSideProps = async ({
preview = false,
query,
}: GetServerSidePropsContext) => {
if (typeof query.query !== 'string') {
return {
notFound: true,
};
}
return {
props: {
query: query.query,
page: query.page ? parseInt(query.page as string) : 0,
footerData: await getFooterData(preview),
menuData: await getMenuData(preview),
},
};
};10 Replies
Cape lionOP
what is default function?
@Cape lion what is default function?
the react component function
can you send that, or at least the props part of it?
Cape lionOP
can you give me an example cause I don't understand what you mean ? 😅
@Cape lion can you give me an example cause I don't understand what you mean ? 😅
send me the entire file
that's giving the error
Cape lionOP
dm you mean? or here?
@Cape lion dm you mean? or here?
send here
Cape lionOP
lol nvm there was revalidate which was not supposed to be there. It managed to sneak itself in to the production code xD