Flutter firebase_dynamic_links : The expression doesn't evaluate to a function, so it can't be invoked

Viewed 37

I am trying to integrate dynamic link in my flutter app using firebase_dynamic_links package and I am not much familiar with dynamic links I am following a tutorial I try following code from tutorial. but on this line FirebaseDynamicLinks.instance.onLink i got the error The expression doesn't evaluate to a function, so it can't be invoked. I search a lot but didn't find any solution.

final PendingDynamicLinkData? data = await FirebaseDynamicLinks.instance.getInitialLink();
    _handleDeepLinks(data);
   FirebaseDynamicLinks.instance.onLink(
     onSucess : (PendingDynamicLinkData dynamicLinkData) async {
       _handleDeepLinks(dynamicLinkData);
     },
     onError : (e) {
       print('This is error $e');
     }
   );
  }

it shows no error like this FirebaseDynamicLinks.instance.onLink; Is there any change in firebase_dynamic_links package?

0 Answers
Related