in_app_notification
1.1.2, released 4 years ago by cb-cloud.com
A Flutter package to show custom in-app notifications with any widgets.
What it does
Allows developers to display custom in-app notifications using any Flutter widget. It requires placing an InAppNotification widget in the app tree and calling a static method to trigger notifications.
AI-written summary of version 1.1.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want to display custom widget-based alerts or notifications within the app.
- You need swipe-to-dismiss gestures for in-app messages.
Skip it when
- You need background push notifications delivered via operating system services.
Strengths
- Supports custom widgets for notification bodies.
- Includes horizontal swipe gesture to dismiss notifications.
- Automatic consideration of safe area padding.
Weaknesses
- Relies on placing an InAppNotification widget high in the app tree.
- Limited documentation beyond basic usage and roadmaps.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
Place the InAppNotification widget above your MaterialApp in the widget tree.
return InAppNotification(
child: MaterialApp(
title: 'In-App Notification Demo',
home: const HomePage(),
),
);
InAppNotification.show(
child: NotificationBody(count: _count),
context: context,
onTap: () => print('Notification tapped!'),
);Alternatives
Packages that do the same job and could replace in_app_notification.
- flutter_local_notifications
For system-level local notifications instead of custom in-app overlay notifications.
96Compare - toastification
Alternative UI options for rich toast and banner notifications.
91Compare - bot_toast
Provides flexible toast and notification overlay management.
50Compare