Question

I've integrated Google Play Services in an Android app which added 500K to my APK file, all I need from Google Pay Services is the ability to +1 a URL.

Is there a way to narrow down the integration and to minimize the impact on the APK size?

Was it helpful?

Solution

I'm not aware of an explicit way to +1 a URL without using the GMS library. You can manually generate a share by passing a URL which might be helpful for you. As an example:

https://plus.google.com/share?url=http://example.com/

Will generate a share link for the site http://example.com. From Android, you could trigger the share by building the link and then encouraging the user to click it or by associating a share button with the action of opening the URL for sharing.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top