Multiple hooks per element in Phoenix LiveView
Phoenix LiveView only supports one hook per element. This article shows how to delegate out to other hooks.
Hi, I’m Andrew, a programmer and entrepreneur from South Africa,
building
Mailcast
for taking control of your email.
Thanks for visiting and reading.
Phoenix LiveView only supports one hook per element. This article shows how to delegate out to other hooks.
How to change your javascript based on the elixir config environment.
A javascript snippet to highlight the elemnts on the page that change.
Add the ability to provide an undo option after a user takes an action within Phoenix LiveView.
How to use a view model to decorate records with UI state in Phoenix LiveView.
Instead of coupling your tests to the HTML structure of your LiveView, use test specific attributes to make your tests more robust. Test specific attributes can be removed to keep your production HTML clean.
How to use put_flash/3 in a LiveComponent without navigation.
Sometimes a controller and a view and a template is just too much. Here's a way to embed heex templates within your Phoenix controllers.
How to get a users timezone when using the datetime-local input type in a Phoenix LiveView.
How do you respond to channel broadcasts in a Phoenix LiveView app layout? You need a way to subscribe across all LiveViews.