Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flicker only on new arch #2663

Open
faljabi opened this issue Jan 31, 2025 · 10 comments
Open

Flicker only on new arch #2663

faljabi opened this issue Jan 31, 2025 · 10 comments
Labels
Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snack or repo is provided

Comments

@faljabi
Copy link

faljabi commented Jan 31, 2025

Description

I am facing an flicker as shown in the attached video when an input inside a View with flex = 1 and alignItems and justContent is 'center'. I noticed also it is happening with other screens without text inputs. Switching back to old arch is resolving the issue.

As a hack on new arch, If I remove flex = 1 and use paddingTop for example to center my content it is working fine.

Any hints please?

Steps to reproduce

  1. Place some label and input in the center using flex = 1 and alignItems, justContent = 'center'.
  2. Focus the input
  3. Notice the flicker only on new arch

Snack or a link to a repository

https://snack.expo.dev/gSa8VH--zqkIt0i8aZsZw

Screens version

4.5.0

React Native version

0.76.6

Platforms

iOS, Android

JavaScript runtime

Hermes

Workflow

React Native (without Expo)

Architecture

Fabric (New Architecture)

Build type

Debug mode

Device

Real device

Device model

iPhone 16 Pro Max, Android Pixel 2

Acknowledgements

Yes

@github-actions github-actions bot added Repro provided A reproduction with a snack or repo is provided Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS labels Jan 31, 2025
@faljabi
Copy link
Author

faljabi commented Jan 31, 2025

WhatsApp.Video.2025-01-31.at.2.56.59.AM.mp4

@kkafar
Copy link
Member

kkafar commented Jan 31, 2025

@faljabi hey,

why do you think this issue is related to react-native-screens? The snack you provided does neither use react-navigation nor react-native-screens? If this issue is reproducible w/o those libraries you should report it directly in react-native's repository. Please let me know whether screens are necessary to reproduce this problem and provide a complete reproduction. Thanks!

@kkafar kkafar added the Close when stale This issue is going to be closed when there is no activity for a while label Jan 31, 2025
@faljabi
Copy link
Author

faljabi commented Jan 31, 2025

@kkafar oh my bad,

I will update the snack and let you know. 🙏🏻

@github-actions github-actions bot removed the Close when stale This issue is going to be closed when there is no activity for a while label Jan 31, 2025
@kkafar
Copy link
Member

kkafar commented Jan 31, 2025

Thanks

@kkafar kkafar added the Close when stale This issue is going to be closed when there is no activity for a while label Feb 1, 2025
@ManAnRuck
Copy link

It seems similar to react-navigation/react-navigation#12278, but I was told to open an issue here 🫣

@github-actions github-actions bot removed the Close when stale This issue is going to be closed when there is no activity for a while label Feb 2, 2025
@kkafar
Copy link
Member

kkafar commented Feb 2, 2025

@ManAnRuck are you able to provide a reproduction here?

@ManAnRuck
Copy link

sure @kkafar 🙂, I think it could be the same issue (but not sure)
https://github.com/ManAnRuck/expo-stack-sidebar-toptabs

Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-02-01.at.19.21.52.mp4

@ManAnRuck
Copy link

with expo go (always new architecture) it happens always.

after running: git clean -xdf && yarn && yarn expo prebuild && yarn iOS
it is the same behaviour.

Then after changing in app.json to not new architecture "newArchEnabled": false, and running git clean -xdf && yarn && yarn expo prebuild && yarn iOS the issue is gone

@faljabi
Copy link
Author

faljabi commented Feb 2, 2025

react-navigation/react-navigation#12278

Yes it is the same issue whenever a view has a flex styles, it flickers on new arch only whenever there is a state update.

@markwitt1
Copy link

I am having an issue which might be related: https://discord.com/channels/695411232856997968/1335675259453706341/1335675259453706341

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: Android This issue is specific to Android Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snack or repo is provided
Projects
None yet
Development

No branches or pull requests

4 participants