Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
maxmarcon committed Mar 19, 2024
1 parent 0341984 commit a609f26
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/live_select.ex
Expand Up @@ -306,7 +306,7 @@ defmodule LiveSelect do
We do (1) by passing a `value_mapper` assign to `LiveSelect`. This is a 1-arity function that expects the struct and maps it to the option that `LiveSelect` should use:
```
<.live_select field={@my_form[:city_search]} value_mapper={&value_mapper/1} mode={:tags} />
<.live_select field={@form[:city_search]} value_mapper={&value_mapper/1} mode={:tags} />
```
```
Expand Down Expand Up @@ -345,7 +345,7 @@ defmodule LiveSelect do
# now we can cast the params:
changeset = CitySearchForm.changeset(params)
{:noreply, assign(socket, changeset: changeset)}
{:noreply, assign(socket, form: to_form(changeset))}
end
```
Expand Down

0 comments on commit a609f26

Please sign in to comment.