Skip to content

Bump phoenix_live_view from 0.17.11 to 0.18.2

Bumps phoenix_live_view from 0.17.11 to 0.18.2.

Changelog

Sourced from phoenix_live_view's changelog.

0.18.2 (2022-10-04)

Bug Fixes

  • Fix match error when defining :values before :default
  • Allow tuples in external redirects
  • Fix race condition on dispatching click away when enter is pressed
  • Fix formatter breaking inline blocks when surrounded by text without whitespace

Enhancements

  • Add intersperse component for rendering a separator between an enumerable

0.18.1 (2022-09-28)

Bug Fixes

  • Fix phx-loading class being applied to dead views
  • Fix <.live_img_preview /> causing invalid attribute errors on uploads
  • Do not fire phx events when element is disabled

Enhancements

  • Support :include option to extend global attributes on a case-by-case basis
  • Warn when accessing a variable binding defined outside of ~H

0.18.0 (2022-09-20)

LiveView v0.18 includes a major new feature in the form of declarative assigns with new attr and slot APIs for specifying which attributes a function component supports, the type, and default values. Attributes and slots are compile-time verified and emit warnings (requires Elixir v1.14.0+).

v0.18 includes a number of new function components which replace their EEx expression counterparts <%= ... %>. For example, live_redirect, live_patch, and Phoenix.HTML's link have been replaced by a unified Phoenix.Component.link/1 function component:

<.link href="https://myapp.com">my app</.link>
<.link navigate={@path}>remount</.link>
<.link patch={@path}>patch</.link>

Those new components live in the Phoenix.Component module. Phoenix.LiveView.Helpers itself has been soft deprecated and all relevant functionality has been migrated. You must import Phoenix.Component where you previously imported Phoenix.LiveView.Helpers when upgrading. You may also need to import Phoenix.Component where you also imported Phoenix.LiveView and some of its functions have been moved to Phoenix.Component.

Additionally, the special let attribute on function components have been deprecated by a :let usage.

Deprecations

  • live_redirect - deprecate in favor of new <.link navigate={..}> component of Phoenix.Component
  • live_patch - deprecate in favor of new <.link patch={..}> component of Phoenix.Component
  • push_redirect - deprecate in favor of new push_navigate function on Phoenix.LiveView

Enhancements

... (truncated)

Commits

Merge request reports