Local Notifications

Viewed 50

I'm building my first app in Flutter and want to include local notifications for Android and iOS. I've searched quite extensively for how to implement these, but every search result on Medium, Youtube, or random website uses flutter_local_notifications on pub.dev (I can't find anything on api.flutter.dev except for icons).

I'm sure it's a great resource, but I've been trying to code everything from scratch rather than use these plugins so I can understand the foundational mechanics better.

Anyone know of a resource to guide me?

1 Answers

As Notifications are pretty platform-specific, there is no direct approach of calling notifications from flutter itself. You rather have to write your own native code for both ios and android in order to send notifications. For android, you can either use Java or Kotlin as a native language, and for iOS, you use Swift.

You can follow this tutorial in order to get your hands on a native method for calling notifications on android.

Related