How to config getJSIModulePackage for multiple JSI packages?
See original GitHub issuePardon my ignorances here, I’m trying to implement WatermelonDB and React Native Reanimated together into one single app, and here’s my MainApplication.java
@Override
protected JSIModulePackage getJSIModulePackage() {
return new JSIModulePackage() {
@Override
public List<JSIModuleSpec> getJSIModules(
final ReactApplicationContext reactApplicationContext,
final JavaScriptContextHolder jsContext
) {
final List<JSIModuleSpec> specs = new ArrayList<>();
specs.add(new ReanimatedJSIModulePackage());
specs.add(new WatermelonDBJSIPackage());
return specs;
}
};
}
Since I have no JAVA experience, so this code is total junk, but the idea of how to enable both JSI Modules in getJSIModulePackage() is a problem I cound’t overcome, could someone please to help?
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:10 (7 by maintainers)
Top Results From Across the Web
Add multiple JSIModule React-Native Android - Stack Overflow
This is the best way: change your code: @Override protected List<JSIModulePackage> getJSIModulePackage() { List<ReactPackage> packages = new ...
Read more >[Android/Java] Allow third-party libraries to automatically setup ...
Add an abstract method like getJSIModulePackages to ReactNativeHost , and load the module packages returned by it into the catalystInstance on ...
Read more >React Native JSI: Part 1 - Getting Started - Notesnook Blog
Inside our instance of ReactNativeHost we are overriding getJSIModulePackage method and returning an new instance of SimpleJsiModulePackage .
Read more >Deep dive into React Native JSI - Teknasyon Engineering
For this reason, we need to do linking operations manually. In MainApplication.java, we need to override getJSIModulePackage method in the ReactNativeHost ...
Read more >@tonclient/lib-react-native-jsi - npm
Start using @tonclient/lib-react-native-jsi in your project by running ... TypeScript icon, indicating that this package has built-in type ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Something like this?
Update Tested and it’s working for me