Skip to content

Conversation

@KimthoHey
Copy link

Fixes crash in React Native 0.76+ with Fabric enabled:

Caused by com.facebook.react.bridge.RetryableMountingLayerException: Unable to find viewState for tag 432

Root Cause: EventDispatcher was initialized too early in the component lifecycle, before the view was properly mounted in Fabric.

Solution:

  • Fixed event dispatcher initialization timing in RCTLoginButton.java
  • Added safety checks for view attachment state and valid IDs
  • Added exception handling to prevent crashes
  • Added Fabric codegen configuration and component specs

Changes:

  • Deferred EventDispatcher initialization until view is attached
  • Added onAttachedToWindow() lifecycle hook
  • Created TypeScript component specifications for Fabric codegen
  • Updated package.json with codegen configuration

Compatibility: ✅ RN 0.76+ (Fabric) ✅ RN 0.63+ (Bridge) ✅ Expo SDK 53+

@KimthoHey KimthoHey changed the title Fixes crash in React Native 0.76+ with Fabric enabled: fix: resolve React Native Fabric mounting crash and add CI test validation Sep 23, 2025
@KimthoHey KimthoHey force-pushed the issues/640-Crash-on-Expo-SDK-53 branch from 2ae886c to 4018381 Compare September 23, 2025 11:03
@KimthoHey KimthoHey changed the title fix: resolve React Native Fabric mounting crash and add CI test validation fix: resolve React Native Fabric mounting crash Sep 23, 2025
@stale
Copy link

stale bot commented Oct 25, 2025

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix This will not be worked on label Oct 25, 2025
@stale stale bot closed this Nov 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wontfix This will not be worked on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant