android tutorial - Declare dependencies for flavors in android | Developer android - android app development - android studio - android app developement



Dependencies can be added for specific product flavors in a similar fashion as build configurations

android {
    ...   
    productFlavors {
        flavor1 {
            //...
        }
        flavor2 {
            //...
        }
    }
}

dependencies {
    flavor1Compile 'com.android.support:appcompat-v7:24.1.1'
    flavor1Compile 'com.google.firebase:firebase-crash:9.4.0'
        
    flavor2Compile 'com.android.support:appcompat-v7:24.1.1'
} 
click below button to copy code from our android learning website - android tutorial - team

Related Searches to Declare dependencies for flavors in android