Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Play Services partial integration

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?

like image 716
Aviran Avatar asked Jan 01 '26 04:01

Aviran


1 Answers

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.

like image 57
class Avatar answered Jan 02 '26 19:01

class



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!