deprecate ReactModuleWithSpec (#36673)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/36673

Changelog: [Android][Deprecated]

in this change, we deprecate ReactModuleWithSpec because it can be replaced with the TurboModule interface which better describes our generated modules.

Reviewed By: cortinico

Differential Revision: D44450959

fbshipit-source-id: adab192593843926f35bdbeb346ef374dd80e615
This commit is contained in:
Phillip Pan
2023-03-29 12:06:52 -07:00
committed by Facebook GitHub Bot
parent 0328a8d26b
commit a4fe9b2b6d
4 changed files with 13 additions and 26 deletions
@@ -52,7 +52,7 @@ package ${packageName};
${imports}
public abstract class ${className} extends ReactContextBaseJavaModule implements ReactModuleWithSpec, TurboModule {
public abstract class ${className} extends ReactContextBaseJavaModule implements TurboModule {
public static final String NAME = "${jsName}";
public ${className}(ReactApplicationContext reactContext) {
@@ -463,7 +463,6 @@ module.exports = {
'com.facebook.react.bridge.ReactApplicationContext',
'com.facebook.react.bridge.ReactContextBaseJavaModule',
'com.facebook.react.bridge.ReactMethod',
'com.facebook.react.bridge.ReactModuleWithSpec',
'com.facebook.react.turbomodule.core.interfaces.TurboModule',
'com.facebook.proguard.annotations.DoNotStrip',
'javax.annotation.Nonnull',