incrementBadgeCount method

dynamic incrementBadgeCount({
  1. required int tab,
})

Increment the badge count E.g. MyNavigationHub.incrementBadgeCount(tab: 0);

Implementation

incrementBadgeCount({required int tab}) async {
  int currentCount =
      (await NyStorage.read(_navigationTabStateName(tab)) ?? 0);
  updateState(_navigationTabStateName(tab), data: currentCount + 1);
}