File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,7 +54,9 @@ sent to the server will be chosen with the following priority:
5454 def handle_event("inc", %{"myvar1" => "val1", "myvar2" => "val2"}, socket) do
5555
5656 If the `phx-value-` prefix is used, the server payload will also contain a `"value"`
57- if the element's value attribute exists.
57+ if the element's value attribute exists. Note that if the element has a `value` property,
58+ like the `<li>` element, it takes precedence over `phx-value-value`. If you need to overwrite
59+ the `"value"` key in the payload, you can use `Phoenix.LiveView.JS.push/3` with its `value` option.
5860
5961 * The payload will also include any additional user defined metadata of the client event.
6062 For example, the following `LiveSocket` client option would send the coordinates and
You can’t perform that action at this time.
0 commit comments