sezaru
Flashy - A small library to extend LV's flash notifications
Hey everyone,
I made a small library to extend the current flash notification functionality from Phoenix and LiveView.
Flashy is a simple replacement for the built-in flash support and components that ships with Phoenix.
Features:
- Keep notifications between redirects;
- Support rendering function and live components as notifications;
- Support auto-hide;
- Supports creation of custom notifications;
- No Javascript library is used.
Here is small video showing it is practice:
You can check it out here: GitHub - sezaru/flashy: Flashy is a small library that extends LiveView's flash support to function and live components.
If you want to test it out first, you can clone my example project here: GitHub - sezaru/flashy_example: Small project showing Flashy features
Most Liked
sezaru
Hey everyone,
I just pushed a new version of Flashy 0.2.0.
The main features of this version are:
- Fixed a bug that would not show notifications in the correct order;
- Added support to fully customize the components CSS and transitions.
@christhekeele I think this version will have all the customization you probably need.
I added a new section to the README explaining step-by-step how to customize the notifications to make them show in the left side as an example, you can find it here:
I also added a branch called left_side_notifications to the flashy_example repo with these customization in case someone want to just see it in action.
TwistingTwists
Lovely stuff. Would give this a spin on first chance I get. ![]()
sezaru
Hey everyone,
I just pushed version 0.2.6 and version 0.2.7.
Version 0.2.6 adds support for adding notifications with a manual key.
Basically you only need this if you want to replace a notification that is already exists with another one.
You do that by adding a custom key when creating the notification to the socket:
put_notification(socket, notification, key: "my_custom_key")
If you want to see this working, you can check it out in the GitHub - sezaru/flashy_example: Small project showing Flashy features project.
Version 0.2.7 adds support for setting the dismiss_time value via a configuration during compile time as requested by @absowoot
config :flashy, dismiss_time: :timer.seconds(5)
sezaru
Cool! Just pushed version 0.2.4 with that support for controllers.
sezaru
Hey everyone,
I just pushed version 0.2.5.
This version fixes the issue reported by @Valeriy and also another issue when using app.js with type="module".







