https://kotlinlang.org logo
#android
Title
# android
n

Nikola Milovic

07/04/2020, 10:38 AM
Any good multi module projects for Android that feature well structured gradle files? Like a Library base module that handles the dependancies. I cannot for the life of me find anything
2
v

Viktor Petrovski

07/04/2020, 5:41 PM
I like to put all my dependencies in a
dependencies.gradle
file and access them in all the module by the name I’ve provided. Here is an example https://github.com/inplayer-org/inplayer-android-sdk/blob/develop/dependencies.gradle You access them in your module gradle file like:
def network = rootProject.ext.networkDependencies
implementation network.gson
Example: https://github.com/inplayer-org/inplayer-android-sdk/blob/develop/InPlayer/build.gradle