This repository was archived by the owner on Jan 28, 2025. It is now read-only.
This repository was archived by the owner on Jan 28, 2025. It is now read-only.
Redirects not working in getStaticProps #2346
Closed
Description
Issue Summary
Redirects are throwing errors in getStaticProps. I know this is not an issue with the code or anything related to the next js because I have checked the local build and it successfully redirects to the targeted page.
Actual behavior
While redirecting it throws an error that the client-side exception occurred. I am unable to explore more about the error. Actual redirection doesn't occur.
Expected behavior
getStaticProps should redirect to the destination path.
Steps to reproduce
- Add redirect to getStaticProps with some external or internal URL.
- Go to the path that should redirect to the targeted URL
- Client-side exception occurs
Versions
- OS/Environment: Mac
- @sls-next/serverless-component version: 3.2.0
- Next.js version: ^11.0.1
Checklist
- You have reviewed the README and FAQs, which answers several common questions.
- You have reviewed our DEBUGGING wiki and have tried your best to include complete information and reproduction steps (including your configuration) as is possible. As there is only one maintainer (who maintains this in his free time) and thus very limited resources, if you have time, please try to debug the issue a bit yourself if possible.
- You have first tried using the most recent
latest
oralpha
@sls-next/serverless-component
release version, which may have already fixed your issue or implemented the feature you are trying to use. Note that the oldserverless-next.js
component and theserverless-next.js
plugin are deprecated and no longer maintained.
Metadata
Metadata
Assignees
Labels
No labels