Is there a way to include node_modules in aar library so that a new android project using this aar library doesn't have to add these dependencies at their end as well?
I wanted to create a react native project which could be integrated in an existing android project as an aar library. Since I couldn't find a way to create an aar library of a react native project, I followed https://facebook.github.io/react-native/docs/integration-with-existing-apps to integrate react native in android app and then create an aar library of it. I managed to do it but the aar file created this way is of very small size (since it doesn't contain node_modules I suppose). So now to use this aar in a fresh android project, I had to install all the node_modules there as well and then specify the path in project's build.gradle like maven { url "$rootDir/node_modules/react-native/android" }
Is there a way that this step is not required at the end of the app that is going to integrate the aar? Besides please correct me if I took a wrong approach somewhere and is there an alternative way to approach this.