I’m experiencing issues with my e-commerce project hosted on Vercel. The project uses Next.js 14 for the frontend and AWS Lambda for the backend. I’m encountering the following problems:
- 404 Errors on Blog Pages:
- When navigating from the home page to certain blog pages, I receive a 404 error.
- However, refreshing the page loads the content correctly.
- And the interesting part is that, this issue does not occur in local builds or even when deployed on Amazon ECS.
404 error when navigating from home page to blog page:
After refreshing the page:
Here when i see the vercel logs, it giving me this error:
- Missing Header and Footer:
- On some product and collection pages, the header and footer (defined in the layout file) are not displayed.
- Refreshing these pages makes the header and footer appear.
Additional Information:
- The project uses dynamic routes with pre-built blog pages.
- These issues are specific to the Vercel deployment and do not occur locally or on other hosting platforms.
Could you please help investigate why these issues are occurring specifically on Vercel? Any guidance on resolving these problems would be greatly appreciated.