Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Need help in understanding flutter_local_notifications and firebase_messaging integration #2198

Closed
becjit opened this issue Jan 2, 2024 · 3 comments

Comments

@becjit
Copy link

becjit commented Jan 2, 2024

Hi,
I am planning to integrate flutter_local_notifications and firebase_messaging. I have gone through multiple issues/notes on the same topic and have some confusions around FirebaseAppDelegateProxyEnabled.

Confusion #1 : https://firebase.flutter.dev/docs/messaging/overview clearly calls out FirebaseAppDelegateProxyEnabled to be set to true while in other references that talks about integrating with flutter_local_notifications the direction is to set it to false

Confusion #2 In this https://firebase.flutter.dev/docs/messaging/notifications page there are steps to integrate with flutter_local_notifications in android but not with ios

Confusion #3 In @MaikuB 's integration example https://github.com/MaikuB/flutter_firebase_local_notifications_examples/blob/updateKotlinSwift/kotlin_swift/ios/Runner/Info.plist for kotlin swift the FirebaseAppDelegateProxyEnabled is not present in info.plist

while in https://github.com/MaikuB/flutter_firebase_local_notifications_examples/blob/updateKotlinSwift/java_objc/ios/Runner/Info.plist is set to false

Confusion #4 As per firebase/flutterfire#6113 it looks like it is not possible to intercept 'notification' at all. Any integration would only with 'data' messages only

I would appreciate your help in clearing these doubts

@MaikuB
Copy link
Owner

MaikuB commented Jan 19, 2024

I would say your best bet is to actually go try to implement to go confirm. If you need more guidance then suggest going to places like Stack Overflow, Discord or Slack. Will mention a few of things with what I know though

  • my own example is purely for my own exploration so is why it's not called out in this plugin's readme. If you're going to look at existing apps, you should be mindful of how old the code is and versions of libraries used. I'm mentioning this as the repo is quite old
  • I'd be more inclined to think the docs to do with FCM plugin are more up to date so would suggest referring to what they have instead. If they have inconsistencies in their own docs then that's not something I can explain
  • Since you mentioned [firebase_messaging] Disable interception of notification to allow for local notification generation firebase/flutterfire#6113, want to mention you will need to figure if you really need to use this plugin with FCM or not to begin with by understanding how the FCM plugin works and if that is sufficient for your purposes

@becjit
Copy link
Author

becjit commented Jan 19, 2024 via email

@MaikuB MaikuB closed this as completed Feb 6, 2024
@MaikuB
Copy link
Owner

MaikuB commented Feb 6, 2024

Thanks will close this but out of interest, what was the approach that worked for you?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants