Skip to content

Conversation

AndreiCalazans
Copy link

@AndreiCalazans AndreiCalazans commented Jun 23, 2025

Description

Reproducible for #2933

What to look for?

There are two problems but one kind of makes the other visible and I'm here because of problem two.

  1. The padding is getting lost when updateScreenSizeFabric runs
  2. But also updateScreenSizeFabric runs when there is a orientation change causing the layout shift

In a large app with many things going when orientation changes this is causing the app to have enourmous UI shifts causing the app to lag and become a bit slow to complete the layout shift. Thus, in this example I needed to create an artificial pressure on the JS thread to make this show up - on a real world app on a lower end device no pressure is needed. The problem goes away when we comment out the updateScreenSizeFabric call.

reproduce-layout-shift-fabric.mp4

Changes

Test code and steps to reproduce

Checklist

@Prajwaltechversant
Copy link

Hi @AndreiCalazans , have you got any workaround for this ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants