If you are on NativeScript 8.1+, and using @nativescript/geolocation plugin 8.1.0, and have googlePlayServicesVersion accidentally set somewhere. Recent updates from this plugin may break your builds on Android.
Related GitHub issue: https://github.com/NativeScript/plugins/issues/364#issuecomment-1321794964
Symtoms
Error: Cannot enable the location service. TypeError: Cannot read property 'PRIORITY_HIGH_ACCURACY' of undefined
How to fix this
Try to remove googlePlayServicesVersion settings from all of your .gradle script or set it to Set it to 21.+. You may have accidentally set it in either app.gradle or before-plugins.gradle
ns clean
ns run android
To clean up and re-build your project.
I saw a lot of website but I believe this one holds something special in it.