⚡ Bolt: Replace Astro <Image> in React with pre-optimized <img> tags - #182
⚡ Bolt: Replace Astro <Image> in React with pre-optimized <img> tags#182fysp11 wants to merge 1 commit into
Conversation
Replaced the incompatible Astro <Image /> component inside ProjectsView.tsx with a standard HTML <img> tag. To retain build-time image optimization, getImage() was used on the server in index.astro to pre-compute optimized WebP images, and pass those string URLs down. This prevents build/render errors while preserving performance. Co-authored-by: fysp11 <13081700+fysp11@users.noreply.github.com>
Preview deployments for fysp11.github.io ⚡️
Commit: Deployment ID: Static site name: |
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
astro:assets<Image />tag inside the ReactProjectsView.tsxcomponent with a standard HTML<img>tag, and shifted the image optimization logic to the server side (index.astro).<Image />component is an Astro component and cannot be safely rendered inside React.tsxfiles dynamically on the client, which can cause hydration issues or build errors.getImage()resolving to small WebP formats./projectsand changing to "list" view to ensure images load correctly andpnpm run checkpasses.PR created automatically by Jules for task 2328763758083184544 started by @fysp11