- [LiveView] Add new
:container
option touse Phoenix.LiveView
- [LiveViewTest] Add
live_isolated
test helper for testing LiveViews which are not routable
- Fix number input handling causing some browsers to reset form fields on invalid inputs
-
Replace
configure_temporary_assigns/2
with 3-tuple mount return, supporting a:temporary_assigns
key -
Do not allow
redirect
/live_redirect
on mount nor in child live views -
LiveSocket
JavaScript constructor now requires explicit dependency injection of Phoenix Socket constructor. For example:```javascript import {Socket} from "phoenix" import LiveSocket from "phoenix_live_view" let liveSocket = new LiveSocket("/live", Socket, {...}) ````
- Fix multi-select decoding causing server error
- Fix multi-select change tracking failing to submit an event when a value is deselected
- Fix live redirect loop triggered under certain scenarios
- Fix params failing to update on re-mounts after live_redirect
- Fix blur event metadata being sent with type of "focus"
phx-value
has no effect, usephx-value-*
instead- The
:path_params
key in session has no effect (usehandle_params
inLiveView
instead)
- Use optimized
insertAdjacentHTML
for faster append/prepend and proper css animation handling - Allow for replacing previously appended/prepended elements by replacing duplicate IDs during append/prepend instead of adding new DOM nodes
- Fix duplicate append/prepend updates when parent content is updated
- Fix JS hooks not being applied for appending and prepended content
- The LiveView
handle_in/3
callback now receives a map of metadata about the client event - For
phx-change
events,handle_in/3
now receives a"_target"
param representing the keyspace of the form input name which triggered the change - Multiple values may be provided for any phx binding by using the
phx-value-
prefix, such asphx-value-myval1
,phx-value-myval2
, etc - Add control over the DOM patching via
phx-update
, which can be set to "replace", "append", "prepend" or "ignore"
phx-ignore
was renamed tophx-update="ignore"