Sitecore / jss

Software development kit for JavaScript developers building web applications with Sitecore Experience Platform
https://jss.sitecore.com
Apache License 2.0
261 stars 272 forks source link

Netlify rewrite issues #1663

Open mg-aceik opened 10 months ago

mg-aceik commented 10 months ago

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

illiakovalenko commented 10 months ago

@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

jflheureux commented 2 weeks ago

Any updates to this issue. I am running into very similar issues.