sezaru / flashy Goto Github PK
View Code? Open in Web Editor NEWFlashy is a small library that extends LiveView's flash support to function and live components.
License: MIT License
Flashy is a small library that extends LiveView's flash support to function and live components.
License: MIT License
It would be helpful to extend the library to be able to select either the current implementation or AlpineJS for all client-side timer processing to relieve the need for extra server interactions. I had a similar requirement in my "multi-select" component to be able to support both AlpineJS and Phoenix's JS events and it works really nicely. Also you may want to copy from that project the mix install task, which automates the required modifications of source code during installation of the library.
I followed the instructions, but when running, I get errors in the console for unknown hook found for both FlashHook
and DisconnectedNotificationHook
. I temporarily fixed it by creating the hooks in my own code and importing them, but I assume I should not have to?
I'm using Elixir 1.15.3, Phoenix 1.7.10 and Phoenix Liveview 0.20.1
Nice project! I suggest you update to a more up to date typedstruct dependency.
The project I'm working on has some large dependencies, so I've enabled splitting in esbuild and set type="module"
for app.js
When trying to import Flashy I am receiving the following error:
[FlashHook is undefined](flashy.min.js:22 Uncaught ReferenceError: FlashHook is not defined)
To replicate, just change app.js type to module. After looking through the JS, it seems that line 5 here is missing a const.
After adding the const, I am able to see the flash notifications but I am also seeing unknown hook found for "FlashHook"
in the console. Any thoughts on how to fix this?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.