Skip to content

Upgrading flutter_local_notifications 2 to 3

Breaking2.0.2 → 3.0.3Breaking1New3Changed3Fixed9Other10

BreakingUpgrade verdict

1 breaking change.

  • If you scheduled repeating notifications, you now pick which parts of the date to repeat on (like the time of day or the day of the week) instead of choosing a repeat frequency.
1 item needs code or config changes
Breaking1
Removes the scheduledNotificationRepeatFrequency parameter of zonedSchedule, replaced by matchDateTimeComponents for recurring notifications.
zonedSchedulescheduledNotificationRepeatFrequencymatchDateTimeComponentsshowDailyAtTime()showWeeklyAtDayAndTime()

Generated by DepDelta from published Dart source. Not mixed with prose notes.

  • removed: enum ScheduledNotificationRepeatFrequency
  • removed: member ScheduledNotificationRepeatFrequency.daily
  • removed: member ScheduledNotificationRepeatFrequency.weekly
  • changed: ctor AndroidNotificationChannel( this.id, this.name, this.description, { this.importance = …, this.playSound = …, this.sound, this.enableVibration = …, this.vibrationPattern, this.showBadge = …, this.enableLights = …, this.ledColor, }) → ctor AndroidNotificationChannel( this.id, this.name, this.description, { this.groupId, this.importance = …, this.playSound = …, this.sound, this.enableVibration = …, this.vibrationPattern, this.showBadge = …, this.enableLights = …, this.ledColor, })
  • changed: method AndroidFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, AndroidNotificationDetails notificationDetails, { @required bool androidAllowWhileIdle, String payload, ScheduledNotificationRepeatFrequency scheduledNotificationRepeatFrequency, }): Future<void> → method AndroidFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, AndroidNotificationDetails notificationDetails, { @required bool androidAllowWhileIdle, String payload, DateTimeComponents matchDateComponents, }): Future<void>
  • changed: method FlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, NotificationDetails notificationDetails, { @required UILocalNotificationDateInterpretation uiLocalNotificationDateInterpretation, @required bool androidAllowWhileIdle, String payload, ScheduledNotificationRepeatFrequency scheduledNotificationRepeatFrequency, }): Future<void> → method FlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, NotificationDetails notificationDetails, { @required UILocalNotificationDateInterpretation uiLocalNotificationDateInterpretation, @required bool androidAllowWhileIdle, String payload, DateTimeComponents matchDateTimeComponents, }): Future<void>
  • changed: method IOSFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, IOSNotificationDetails notificationDetails, { @required UILocalNotificationDateInterpretation uiLocalNotificationDateInterpretation, String payload, ScheduledNotificationRepeatFrequency scheduledNotificationRepeatFrequency, }): Future<void> → method IOSFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, IOSNotificationDetails notificationDetails, { @required UILocalNotificationDateInterpretation uiLocalNotificationDateInterpretation, String payload, DateTimeComponents matchDateTimeComponents, }): Future<void>
  • changed: method MacOSFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, MacOSNotificationDetails notificationDetails, { String payload, ScheduledNotificationRepeatFrequency scheduledNotificationRepeatFrequency, }): Future<void> → method MacOSFlutterLocalNotificationsPlugin.zonedSchedule( int id, String title, String body, TZDateTime scheduledDate, MacOSNotificationDetails notificationDetails, { String payload, DateTimeComponents matchDateTimeComponents, }): Future<void>
  • added: class AndroidNotificationChannelGroup
  • added: ctor AndroidNotificationChannelGroup( this.id, this.name, { this.description, })
  • added: enum DateTimeComponents
  • added: field AndroidNotificationChannel.groupId: final String
  • added: field AndroidNotificationChannelGroup.description: final String
  • added: field AndroidNotificationChannelGroup.id: final String
  • added: field AndroidNotificationChannelGroup.name: final String
  • added: field AndroidNotificationDetails.subText: final String
  • added: field AndroidNotificationDetails.usesChronometer: final bool
  • added: member DateTimeComponents.dayOfWeekAndTime
  • added: member DateTimeComponents.time
  • added: method AndroidFlutterLocalNotificationsPlugin.createNotificationChannelGroup( AndroidNotificationChannelGroup notificationChannelGroup): Future<void>
  • added: method AndroidFlutterLocalNotificationsPlugin.deleteNotificationChannelGroup(String groupId): Future<void>