jss
jss copied to clipboard
Netlify rewrite issues
Describe the Bug
I'm doing a POC on Netlify and have run into a few issues. First, ran into https://github.com/netlify/next-runtime/issues/2284 where the OOTB next.config.js rewrites don't work. Had to force downgrade to 13.4.12 and use --legacy-peer-deps as it conflicted with JSS 21.5.0. That worked for /-/jssmedia rewrites but not /-/media. I haven't been able to resolve that. The next issue is that calling next/image seems to be having issues too - gives a 400 bad request. Upgrading to Next 13.5.x gives this issue.
I realise this is all Netlify so just opening here for visibility and perhaps you can escalate via the new Sitecore and Netlify partnership channels.
To Reproduce
Try Next.js on Netlify and use the default rewrites.
Expected Behavior
Rewrites should work.
Possible Fix
No response
Provide environment information
- Sitecore Version: XM Cloud
- JSS Version: 21.5.0
@mg-aceik Thank you for submitting your contribution! I've added a ticket containing all the details. It has been added to our internal backlog for thorough review