⚡ bolt: [performance improvement]#29
Conversation
Replaced the width animation on .scroll-progress with a GPU-accelerated transform: scaleX(0...1) to avoid layout thrashing during scroll events.
|
👋 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. |
Deploying personal-website with
|
| Latest commit: |
eb68d8a
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://9ebeb842.personal-website-5ns.pages.dev |
| Branch Preview URL: | https://bolt-scroll-progress-gpu-151.personal-website-5ns.pages.dev |
💡 What: Replaced the CSS
widthtransition and JSstyle.widthupdates on the.scroll-progresselement with atransform: scaleX()approach.🎯 Why: Animating the
widthproperty during a high-frequency event like scrolling forces the browser to recalculate the layout and repaint on every frame, which causes jank. By usingtransform: scaleX(), the animation is offloaded to the GPU compositor layer, skipping layout entirely.📊 Impact: Reduces layout recalculations (thrashing) to zero for the progress bar during scrolling, resulting in smoother 60fps performance, especially on low-end devices.
🔬 Measurement: Verify by scrolling the page while recording a Performance profile in Chrome DevTools. Observe that "Recalculate Style" and "Layout" events caused by the progress bar update are no longer present.
PR created automatically by Jules for task 15132170364255815083 started by @dttdrv