phoenix_live_view changelog


Hey there, awesome developers! 🎉 We've got some cool updates and improvements for you. Check out the latest changes:

Changelog

New feature: Use the new :mfa field for route checking

  • We've jazzed up the route checking in Phoenix LiveView by introducing the new :mfa field! 🚀
  • This new field adds detailed metadata about the live_view, action, and the number of arguments for the mount function.
  • Also, a heads-up: there's a note to remove the :log_module when Phoenix version 1.8 or higher is required.
  • Files touched: lib/phoenix_live_view/router.ex

Improvement: Clarify required id for live_file_input, closes #3330

  • Made it crystal clear that the id attribute for live_file_input cannot be overwritten. 🔍
  • Added guidance on creating a label with a for attribute pointing to the UploadConfig ref.
  • Provided tips on implementing drag and drop functionality by annotating the droppable container with phx-drop-target.
  • Files touched: lib/phoenix_component.ex

Happy coding! 💻✨

Included Commits

2024-07-03T19:11:06 See commit

This commit clarifies the required id for live_file_input in Phoenix Component. It mentions that the id attribute cannot be overwritten, but a label can be created with a for attribute pointing to the UploadConfig ref. This ensures that the live_file_input works correctly and provides guidance on how to implement drag and drop functionality by annotating the droppable container with a phx-drop-target.

The changes made in the lib/phoenix_component.ex file include adding 3 lines of code and making 3 modifications. The clarification provided in this commit helps developers understand how to correctly use the live_file_input component in Phoenix Component and ensures that the id attribute is not overwritten. Overall, this commit aims to improve the functionality and usability of live_file_input in Phoenix Component by providing clear guidance on how to implement it.

Files changed

  • lib/phoenix_component.ex
2024-06-30T15:42:40 See commit

This commit introduces the use of the new :mfa field in route checking in the lib/phoenix_live_view/router.ex file. The commit includes modifications to the file, with 3 additions and 2 deletions, resulting in a total of 5 changes. Specifically, the changes involve updating the metadata by adding the new :mfa field, which includes information about the live_view, action, and number of arguments for the mount function. Additionally, there is a note to remove the :log_module when Phoenix version 1.8 or higher is required.

Overall, this commit enhances route checking in Phoenix LiveView by utilizing the new :mfa field in the metadata. It provides more detailed information about the live_view, action, and function arguments, while also mentioning a potential update to remove the :log_module in future versions of Phoenix.

Files changed

  • lib/phoenix_live_view/router.ex