Next.js with custom cache handler fails to serve pre-rendered static HTML (uses getStaticProps) and incremental static regeneration
Because in the examples, there is a lack of reading static HTML from the disk, and the cache is empty, the app fails to serve such pages and shows 404 page.
- Build and start the app with
npm run build && npm run start
. - Open http://localhost:3000/should-work in the browser.
The page is loaded with content and status code 200.
404 page is shown.