avioli / uni_links

Flutter plugin for accepting incoming links.
BSD 2-Clause "Simplified" License
563 stars 303 forks source link

Can't get it to work on Android with subdomain #189

Closed astheras closed 5 months ago

astheras commented 1 year ago

I'm using https schemes and am testing on my samsung s22, which is running Android 13

and i cant make linkStream.listen to fire.

manifest

            <intent-filter
                android:autoVerify="true"
                >
                <action android:name="android.intent.action.VIEW" />

                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
                <data
                    android:scheme="https"
                    android:host="testshare.host.us"
                />
            </intent-filter>

init code

 Future<void> _initUniLinks() async {
    try {
      final String? initialLink = await getInitialLink();
      if (initialLink != null) {
        processLink(initialLink);
      }
    } on PlatformException {
      print('DeepLinksService PlatformException:');
    }
    _subUniLinks = linkStream.listen(
      processLink,
      onError: (err) {
        print('DeepLinksService error: $err');
      },
    );
  }

and when i tap on link on messengers, processLink never fires. What i'm doing wrong? Thx for an answer

astheras commented 1 year ago

not actual, that is because of andriod 13

rvharjinderbains commented 1 year ago

@astheras Did you get any solution. I am also facing same in Android 13

ayushsingh363 commented 9 months ago

any updates? I am facing the same issue on android 14

vichuer commented 9 months ago

Actually linkStream.listen is working but only for the first time. After the app is terminated or exited then that is not working (Android 13). Anyone got any solution?

rvharjinderbains commented 9 months ago

Hi all, I have followed this official documentation:- https://developer.android.com/training/app-links/deep-linking. And it is working fine. If you are getting specific error then please share.

avioli commented 5 months ago

This package is now marked as discontinued and app_links recommended replacement.