Bebekucing Bebekucing -4 years ago 310
iOS Question

Using Google Service for iOS without using GoogleService-Info.plist

I am able to use both Google SignIn and Analytics using GoogleService-Info.plist.

However, to reduce dependency, I want to move the information from the GoogleService-Info.plist into another .plist that contains my other information.

Would this be possible? If so, how can I do this?

Answer Source

You can - both libraries allow you to configure them manually. You'll want to drop any references to GGLContext, and just setup the libraries directly:

[GIDSignIn sharedInstance].clientID = @"YOUR_CLIENT_ID";


[[GAI sharedInstance] trackerWithTrackingId:@"UA-XXXX-Y"]; 

You can check the reference docs for Analytics and Sign In for more.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download