Skip to content

Commit 677e572

Browse files
committed
Improve docs
1 parent 309d62e commit 677e572

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

lib/phoenix_html.ex

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ defmodule Phoenix.HTML do
3737
3838
## Form handling
3939
40-
See `Phoenix.HTML.Form`.
40+
This libraries also provides an abstraction and a protocol
41+
to build forms. See `Phoenix.HTML.Form`.
4142
4243
## JavaScript library
4344

lib/phoenix_html/form_data.ex

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
defprotocol Phoenix.HTML.FormData do
22
@moduledoc """
3-
Converts a data structure into a `Phoenix.HTML.Form` struct.
3+
A protocol for converting data structure into a `Phoenix.HTML.Form` struct.
44
5-
## Ecto integration
6-
7-
Phoenix provides integration of forms with Ecto changesets and data
8-
structures via the [phoenix_ecto](https://hex.pm/packages/phoenix_ecto) package.
9-
If a project was generated without Ecto support that dependency will need to be
10-
manually added.
5+
The functions here are rarely invoked directly by application developers.
6+
Rather, this is low-level entrypoint used by libraries. For working
7+
with forms in your Phoenix application, you likely want to use
8+
[`Phoenix.Component.to_form/2`](https://hexdocs.pm/phoenix_live_view/Phoenix.Component.html#to_form/2)
9+
instead.
1110
"""
1211

1312
@doc """

0 commit comments

Comments
 (0)