Skip to content

[pull] master from MLH-Fellowship:master#194

Merged
pull[bot] merged 1 commit intoYashKumarVerma:masterfrom
MLH-Fellowship:master
Dec 8, 2020
Merged

[pull] master from MLH-Fellowship:master#194
pull[bot] merged 1 commit intoYashKumarVerma:masterfrom
MLH-Fellowship:master

Conversation

@pull
Copy link
Copy Markdown

@pull pull bot commented Dec 8, 2020

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

Summary:
As part of the initialization of Native View configs, the PaperUIManager.getViewManagerConfig() method calls the native side to lazy initialize iOS Native components. This is necessaary to make ensure that native classes are loaded and initialized before a view is created.
Note that this requirement is only necessary when Fabric is disabled.

As part of JS ViewConfigs, we removed the native call to lazy initialize iOS native components. This causes a crash during the creation of NativeViews when JS ViewConfigs are enabled and Fabric is disabled. The rootcase of the exception is that native classes are not properly initialized when the createView method is executed in iOS.

This diff forces the lazy initialization of iOS Native components when JS View configs are enabled and Fabric is disabled. This new mechanism is executed as part of the creation of views and it's ONLY going to be executed when the user navigates to a NON-FABRIC screen, JS ViewConfigs are enabled and the component is not initialized yet.

The extra cost should be minimal or zero.

changelog: [internal] internal

Reviewed By: fkgozali

Differential Revision: D25387014

fbshipit-source-id: fe3bc42f803a805192b419bfb4b7a6b5b1b71b60
@yashkumarverma-assistant
Copy link
Copy Markdown

Thanks @pull[bot], for opening the pull request! 🙌
One of our team-mates will review the pull request soon. ✅

@pull pull bot added the ⤵️ pull label Dec 8, 2020
@pull pull bot merged commit f964787 into YashKumarVerma:master Dec 8, 2020
@yashkumarverma-assistant
Copy link
Copy Markdown

Congratualtions @pull[bot], your pull request is merged! 🎉
Thanks for your contributions.🙌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant