android - Gradle: "apply plugin" at the top or at the bottom -


has same effect add "apply plugin" @ beginning or end of file build.gradle in android studio projects?

for example add 'com.google.gms.google-services' plugin, firebase official documentation recommends adding @ end, i've seen other codes add @ beginning.

i know question seems irrelevant, i'm developing plugin android studio manage dependencies , have doubt.

apply plugin botton or top

thanks in advance

gradle scripts interpreted top bottom order can important. keep in mind gradle has configuration phase , execution phase order isn't important. it's common apply plugins @ top of script since plugins add extension objects , tasks gradle model can configured lower down in build script.

for example, can't following because test task added java plugin:

test {    include 'org/foo/**' } apply plugin: 'java' 

Comments

Popular posts from this blog

unity3d - Rotate an object to face an opposite direction -

angular - Is it possible to get native element for formControl? -

javascript - Why jQuery Select box change event is now working? -