Next.js - static export using generateStaticParams completes successfully but .html files are not created

82 Views Asked by At

I've been struggling with building next.js app to prepare it for production. I have a Payload CMS and worked on next.js components to have fully localized structure. Everything works fine and resolves all pages in dev.

When i build "build": "cross-env NODE_ENV=production yarn build:payload && yarn build:server && yarn copyfiles && yarn build:next", it will complete successfully, with multiple pages being fetched for every locale. There are only some warnings when building and no errors. Here is the output from the build:enter image description here

After it's completed all i get in out folder is index.html and 404.html. No pages that are under [locale] folder are generated as static sites

Is there something I am missing?

I tried building it with different configurations of files and folder structure. Tried creating static page folders and they are generated fine.

0

There are 0 best solutions below