-
Notifications
You must be signed in to change notification settings - Fork 24.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use getter instead of constant to provide access to FabricUIManager b…
…inding Summary: The `FabricUIManager` module was providing access to the global binding defined by Fabric, adding proper typing for it. The problem about this module is that it only evaluated the global binding once (during module evaluation) and it cached the result. If this module happened to be loaded before the binding is defined, which can happen in apps using the legacy renderer and Fabric together, this modules caches an `undefined` value indefinitely. This refactors the module as a getter function to make sure this lazy behavior is handled correctly in the callsites. Changelog: [Internal] Reviewed By: javache Differential Revision: D44065186 fbshipit-source-id: 7c5cfe674605f03ecb8ca0dabc4c823e0013da6b
- Loading branch information
1 parent
913732b
commit 0875796
Showing
3 changed files
with
15 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters