Flutter - How to know if user shared my app or not?

640 Views Asked by At

I have implemented the below given code to let user share my app. It works fine, but how can I know if the user actually shared my app or not? Because my app unlocks a certain feature if the user shares the app.

[Package used:- share_plus 3.0.4 ]

onTap: () async {
                            const _textShareUrl =
                                'https://www.youtube.com/watch?v=CNUBhb_cM6E&list=PLk6qkmrzOcdx5R4-UqI_jDPYsLWNnZ1dq&index=2';
                            await Share.share(
                                'Social share test\n\n$_textShareUrl');
                            Future.delayed(const Duration(seconds: 10), () {
                              setState(() => _share = true);
                            });
                          },
1

There are 1 best solutions below

0
Patrick On