phoenix_live_view
Advanced tools
Changelog
0.17.9 (2022-04-07)
phx-update
valueChangelog
0.17.8 (2022-04-06)
phx-change
on individual inputsMouseEvent
on client:bubbles
option to JS.dispatch
to control event bubblingliveSocket
instance on hookscsrf_token
for forms without action, reducing the payload during phx-change/phx-submit eventsChangelog
0.17.7 (2022-02-07)
live_redirect
links are clicked when not connected in certain casesChangelog
0.17.6 (2022-01-18)
JS.set_attribute
and JS.remove_attribute
sticky: true
option to live_render
to maintain a nested child on across live redirectsphx:show-start
, phx:show-end
, phx:hide-start
and phx:hide-end
on JS.show|hide|toggle
get_connect_info/2
that also works on disconnected renderLiveSocket
constructor options for configuration failsafe behavior via new maxReloads
, reloadJitterMin
, reloadJitterMax
, failsafeJitter
optionsphx-disable-with
failing to disable elements outside of formsphx-click-away
not respecting phx-target
JS.push
with :target
failing to send to correct component in certain casesPhoenix.LiveView.get_connect_info/1
in favor of get_connect_info/2
Phoenix.LiveViewTest.put_connect_info/2
in favor of calling the relevant functions in Plug.Conn
Phoenix.LiveView.consume_uploaded_entry/3
and Phoenix.LiveView.consume_uploaded_entries/3
. The callback must return either {:ok, value}
or {:postpone, value}
. Returning any other value will emit a warning.Changelog
0.17.5 (2021-11-02)
phx-click-away
if element is not visiblephx-remove
failing to tear down nested live childrenChangelog
0.17.4 (2021-11-01)
Changelog
0.17.3 (2021-10-28)
Changelog
0.17.2 (2021-10-22)
to
target for JS.show|hide|dispatch
Changelog
0.17.1 (2021-10-21)
phx
binding interactionsChangelog
0.17.0 (2021-10-21)
on_mount
changesThe hook API introduced in LiveView 0.16 has been improved based on feedback.
LiveView 0.17 removes the custom module-function callbacks for the
Phoenix.LiveView.on_mount/1
macro and the :on_mount
option for
Phoenix.LiveView.Router.live_session/3
in favor of supporting a custom
argument. For clarity, the module function to be invoked during the mount
lifecycle stage will always be named on_mount/4
.
For example, if you had invoked on_mount/1
like so:
on_mount MyAppWeb.MyHook
on_mount {MyAppWeb.MyHook, :assign_current_user}
and defined your callbacks as: