Images in src
folder are not working in vercel branch preview with deployment protection enabled
#10752
Labels
src
folder are not working in vercel branch preview with deployment protection enabled
#10752
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
I have not fully understood the cause of this bug, but I am able to reproduce it with a minimal example. It is possible this is entirely on vercel's side but I'm hoping to gain some insight to what's causing this issue here.
It is possible that this bug is also caused under different circumstances, but this is the specific set of conditions I found (also see linked stackblitz). The project must be set to "hybrid" mode and the vercel integration must be added. On pages that are not prerendered, i.e
export const prerender = false;
is set, images imported won't show on vercel preview deployments when deployment protection (vercel authentication) is enabled for that environment (only alt text is shown). The network tab shows 404 responses for the image requests. Prerendered pages, local development and when deployed to vercel's production environment, everything works as expected.When I disable vercel authentication in the project settings the 404 responses disappear.
Please let me know if this issue is entirely on Vercel's end so I can file a bug report with them.
What's the expected result?
Images should work when vercel deployment protection is active.
Link to Minimal Reproducible Example
https://stackblitz.com/~/github.com/Trombach/astro-image-test
Participation
The text was updated successfully, but these errors were encountered: