Invalid value returned by getStaticPaths.
InvalidGetStaticPathsReturn: Invalid type returned by
getStaticPaths
. Expected anarray
, gotRETURN_TYPE
(E03011)
What went wrong?
Section titled What went wrong?getStaticPaths
’s return value must be an array of objects.
export async function getStaticPaths() {
return [ // <-- Array
{ params: { slug: "blog" } },
{ params: { slug: "about" } }
];
}
See Also: