Hi, so I'm getting an error when building that doesn't happen when using localhost.
Im using Next 13.
So the website I'm building has normal pages and also has a landing page section, so i created a page type called learn for the landing pages.
In localhost I can go to the landing page I created, but when I build it gives me this error:
Error: Failed to collect page data for /learn/[uid]
In next.js I created a folder called learn and added a folder called [uid] and inside that I created a file called page.js and added the code snippets that prismic gave me for the learn page type.
In prismicio file I added this:
const routes = [
{
type: "homepage",
path: "/",
},
{
type: "learn",
path: "/learn/:uid",
},
{
type: "page",
path: "/:uid",
},
];
Does anyone know what could cause this error?
Thanks