diff --git a/android/app/src/main/java/com/rnnewarchitectureapp/MainApplication.java b/android/app/src/main/java/com/rnnewarchitectureapp/MainApplication.java index 03ca3f7b..bbdbe183 100644 --- a/android/app/src/main/java/com/rnnewarchitectureapp/MainApplication.java +++ b/android/app/src/main/java/com/rnnewarchitectureapp/MainApplication.java @@ -28,12 +28,15 @@ import com.facebook.react.fabric.FabricJSIModuleProvider; import com.facebook.react.module.model.ReactModuleInfo; import com.facebook.react.module.model.ReactModuleInfoProvider; +import com.facebook.react.uimanager.ViewManager; import com.facebook.react.uimanager.ViewManagerRegistry; import com.facebook.soloader.SoLoader; +import com.rnnewarchitectureapp.components.AnswerViewerManager; import com.rnnewarchitectureapp.modules.MainApplicationTurboModuleManagerDelegate; import com.rnnewarchitectureapp.modules.NativeAnswerSolver; import java.lang.reflect.InvocationTargetException; import java.util.ArrayList; +import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -83,6 +86,22 @@ public ReactModuleInfoProvider getReactModuleInfoProvider() { }; } }); + packages.add(new ReactPackage() { + @NonNull + @Override + public List createNativeModules( + @NonNull ReactApplicationContext reactContext) { + return Collections.emptyList(); + } + + @NonNull + @Override + public List createViewManagers( + @NonNull ReactApplicationContext reactContext) { + // Your ViewManager is returned here. + return Collections.singletonList(new AnswerViewerManager()); + } + }); return packages; }