Uh oh!
There was an error while loading. Please reload this page.
[0.64] Enable support for C++ TurboModules (#6804) - #6814
[0.64] Enable support for C++ TurboModules (#6804)#6814Vladimir Morozov (vmoroz) merged 2 commits into
Conversation
* Enable support for C++ TurboModules * Change files * Fix compilation issues * Attempt to fix the CLI test for Nuget with binaries * Address PR feedback * Format code * Address PR feedback * Throw an exception in AbiCallInvoker::invokeSync as in Instance::JSCallInvoker::invokeSync * Format code # Conflicts: # vnext/JSI/Universal/ChakraJsiRuntime_edgemode.cpp
Deleted user (ghost)
commented
Jan 4, 2021
Hello Vladimir Morozov (@vmoroz)! Because this pull request has the Do note that I've been instructed to only help merge pull requests of this repository that have been opened for at least 10 hours, a condition that will be fulfilled in about 9 hours 55 minutes. No worries though, I will be back when the time is right! 😉 p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me ( |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Cherry pick the #6804 from master branch: Enable support for C++ TurboModules
The #6804 description:
In this PR we enable support for C++ TurboModules as they defined in react-native package.
The C++ TurboModules use JSI and we can enable their support based on our ABI-safe JSI implementation.
The only additional code that we needed to add is the ABI-safe wrapper for CallInvoker and ABI-safe registration of TurboModules.
The TurboModules can use the same base types as in the react-native package.
Though we had to do a small fix to the TurboModuleUtils.h to avoid unnecessary dependency on Folly.
We have added new JsiTurboModuleTests to test the use of the TurboModules.
It shows that the TurboModule must be inherited from the
facebook::jsi::TurboModuleand registered using the Package provider that might look as in the test:This code uses the new
AddTurboModuleProvidermethod to create an ABI safe provider for the TurboModule.Note that C++ TurboModule use code generation. In this PR we do not implement the code generation. We just provide a foundation for it. The code generation will be added in the follow up PRs.
Microsoft Reviewers: Open in CodeFlow