sbuttgereit
This is a bit of a silly question, probably nit-picky, and ultimately not too important.
I’m reviewing the Phoenix.HTML.Form documentation and something struck me as odd in the documentation: as expected the module’s struct is represented by a typespec t/0 defining the type of the struct (Phoenix.HTML.Form — Phoenix.HTML v4.3.0)… but the explanatory documentation of the struct appears separately in the “Functions” section under “%Phoenix.HTML.Form{}” (Phoenix.HTML.Form — Phoenix.HTML v4.3.0).
My question is why this bifurcation in the documentation for this struct? Is there some rationale or standard that I’m missing about documenting structs that would lead to this split? I do notice that one of the struct fields, action is left undocumented, but the split has me wondering if the action field is intentionally undocumented (maybe it’s not to be considered “public”) or if the typespec has been updated and the explanatory documentation just hasn’t been maybe because there’s two places seemingly documenting the same thing. Is the typespec in the docs only there because the typespec exists?
Just curious…
Trending in Discussions
Other Trending Topics
Latest Phoenix Threads
Chat & Discussions>Discussions
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #blog-post
- #phoenix_html
- #iex
- #ai
- #graphql
- #genstage
- #elixirconf-us
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #security
- #hex










Showing Posts 1 to 1- Show Best Posts
- Show All Posts (oldest first)
- Show All Posts (newest first)
woylie
I would expect this
@docto be a@typedocplaced right before the@type: phoenix_html/lib/phoenix_html/form.ex at v3.3.1 · phoenixframework/phoenix_html · GitHub. Then the struct would not appear under theFunctionsheader.