[{"name":"NativeForm","comment":" Using browser `document` to decode the current values of forms at anytime.\n\n\n## Types\n\n@docs Value\n\n\n## Helper\n\n@docs decoder\n\n","unions":[{"name":"Value","comment":" Values from form fields are either `String` or `List String`\n\ne.g. values for `input [ type_ \"number\" ] []` will still be a `String` since\nand is entirely up to your application to convert and validate it with\n`String.toInt` or `String.toFloat`\n\n","args":[],"cases":[["OneValue",["String.String"]],["ManyValues",["List.List String.String"]]]}],"aliases":[],"values":[{"name":"decoder","comment":" Given the `id` attribute of a `<form>` tag, we can decode the current\nform values into a List of key values.\n\n    view model =\n        form [ id \"edituserform123\" ]\n            []\n\n    update msg model =\n        ( { model\n            | formFields =\n                NativeForm.decoder \"edituserform123\" model.document\n                    |> Result.withDefault []\n          }\n        , Cmd.none\n        )\n\nNOTE: We are returning a `List` instead of `Dict` because on form submit, duplicate\nnames are preserved. So we are preserving them here too.\n\n<https://developer.mozilla.org/en-US/docs/Web/API/Document/forms>\n<https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement/elements>\n\n","type":"String.String -> Json.Decode.Decoder (List.List ( String.String, NativeForm.Value ))"}],"binops":[]}]