Flowbite - open-source UI components for Phoenix Framework (Elixir)

There seems to be an issue with the Flowbite events not triggering after LiveView navigation but the fix is pretty easy as pointed by @egze here and here:

window.addEventListener('phx:page-loading-stop', (event) => {
  // trigger flowbite events
  window.document.dispatchEvent(new Event("DOMContentLoaded", {
    bubbles: true,
    cancelable: true
  }));
});
1 Like