badge_kit 0.1.0
badge_kit: ^0.1.0 copied to clipboard
A Flutter plugin to update the app icon badge and clear notifications through a single API. Swift Package Manager only on iOS.
Changelog #
0.1.0 #
Initial release.
setBadge(int count)— set the app icon badge count.clearBadge({bool removeNotifications})— clear the badge, optionally removing all notifications from the notification center.isBadgeSupported()— check whether the device/launcher supports badges.clearAllNotifications()— remove all delivered notifications.clearNotificationsByTag(String tag)— remove delivered notifications by tag.clearNotificationsByTags(List<String> tags)— remove delivered notifications matching any of the given tags in a single pass.- Android: notification clearing by tag(s); numeric badges are intentionally
not supported (modern launchers use notification dots driven by active
notifications), so
setBadgeis a no-op andisBadgeSupported()returnsfalse. - iOS: Swift Package Manager only (no CocoaPods podspec); requires
Flutter 3.44+. Uses
UNUserNotificationCenter.setBadgeCounton iOS 16+.