generateStaticParams
issue with output: "export"
in config during development
#64906
Labels
bug
Issue was opened via the bug report template.
Output (export/standalone)
Related to the the output option in `next.config.js`.
Link to the code that reproduces this issue
https://github.com/hsucherng/nextjs-genstaticparams-output-export-issue
To Reproduce
npm run dev
.Current vs. Expected behavior
Current behaviour: When I try to view
http://localhost:3000/en
, an error occurs:Error: Page "/[lang]/page" is missing exported function "generateStaticParams()", which is required with "output: export" config
.Expected behaviour: I should be able to view
http://localhost:3000/en
without any errors.Provide environment information
Which area(s) are affected? (Select all that apply)
Output (export/standalone)
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
I've tried with 14.1.3 and 14.2.2. The issue happens on both versions.
npm run dev
works fine untiloutput: "export"
is added into the Next config.A side note that
npm run build
works as intended. It isnpm run dev
that does not work as expected.The text was updated successfully, but these errors were encountered: