mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Call Turbo Module methods 'methods' in the Turbo Module JSON schema (#44919)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/44919 ## Changelog: [Internal] [Fixed] - Call Turbo Module methods 'methods' in the Turbo Module JSON schema We don't support `properties` on Turbo Modules. We only support methods (even eventEmitters are just methods) Reviewed By: javache Differential Revision: D58510557 fbshipit-source-id: 02b1dc93a37b58b47bb9fd94a9658b5a7301bf55
This commit is contained in:
committed by
Facebook GitHub Bot
parent
358fe46969
commit
810a516475
+3
-7
@@ -445,12 +445,8 @@ module.exports = {
|
||||
const outputDir = `java/${normalizedPackageName.replace(/\./g, '/')}`;
|
||||
|
||||
Object.keys(nativeModules).forEach(hasteModuleName => {
|
||||
const {
|
||||
aliasMap,
|
||||
excludedPlatforms,
|
||||
moduleName,
|
||||
spec: {properties},
|
||||
} = nativeModules[hasteModuleName];
|
||||
const {aliasMap, excludedPlatforms, moduleName, spec} =
|
||||
nativeModules[hasteModuleName];
|
||||
if (excludedPlatforms != null && excludedPlatforms.includes('android')) {
|
||||
return;
|
||||
}
|
||||
@@ -467,7 +463,7 @@ module.exports = {
|
||||
'javax.annotation.Nonnull',
|
||||
]);
|
||||
|
||||
const methods = properties.map(method => {
|
||||
const methods = spec.methods.map(method => {
|
||||
if (method.name === 'getConstants') {
|
||||
return buildGetConstantsMethod(method, imports, resolveAlias);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user