···11import formz/field.{field}
22import formz/formz_use as formz
33-import formz/input
43import formz/string_generator/fields
5465pub fn make_form() {
···1110 use c <- formz.with(field("c", fields.number_field()))
1211 use d <- formz.with(field("d", fields.boolean_field()))
1312 use e <- formz.with(field("e", fields.email_field()))
1414- use f <- formz.with(field("f", fields.hidden_field()))
1515- use g <- formz.with(field("g", fields.enum_field(letters())))
1616- use h <- formz.with(field("h", fields.indexed_enum_field(choices)))
1717- use i <- formz.with(field("i", fields.list_field(["Dog", "Cat", "Bird"])))
1313+ use f <- formz.with(field("g", fields.enum_field(letters())))
1414+ use g <- formz.with(field("h", fields.indexed_enum_field(choices)))
1515+ use h <- formz.with(field("i", fields.list_field(["Dog", "Cat", "Bird"])))
18161919- formz.create_form(#(a, b, c, d, e, f, g, h, i))
2020-}
2121-2222-pub fn handle_get(form) {
2323- form
2424- |> formz.update_input("f", input.set_value(_, "hidden"))
1717+ formz.create_form(#(a, b, c, d, e, f, g, h))
2518}
26192720pub type Alphabet {
···11+# formz_string
22+33+[](https://hex.pm/packages/formz_string)
44+[](https://hexdocs.pm/formz_string/)
55+66+```sh
77+gleam add formz_string@1
88+```
99+```gleam
1010+import formz_string
1111+1212+pub fn main() {
1313+ // TODO: An example of the project in use
1414+}
1515+```
1616+1717+Further documentation can be found at <https://hexdocs.pm/formz_string>.
1818+1919+## Development
2020+2121+```sh
2222+gleam run # Run the project
2323+gleam test # Run the tests
2424+```
+20
formz_string/gleam.toml
···11+name = "formz_string"
22+version = "1.0.0"
33+44+# Fill out these fields if you intend to generate HTML documentation or publish
55+# your project to the Hex package manager.
66+#
77+# description = ""
88+# licences = ["Apache-2.0"]
99+# repository = { type = "github", user = "", repo = "" }
1010+# links = [{ title = "Website", href = "" }]
1111+#
1212+# For a full reference of all the available options, you can have a look at
1313+# https://gleam.run/writing-gleam/gleam-toml/.
1414+1515+[dependencies]
1616+formz = { path = "../formz" }
1717+gleam_stdlib = ">= 0.34.0 and < 2.0.0"
1818+1919+[dev-dependencies]
2020+gleeunit = ">= 1.0.0 and < 2.0.0"
+14
formz_string/manifest.toml
···11+# This file was generated by Gleam
22+# You typically do not need to edit this file
33+44+packages = [
55+ { name = "formz", version = "1.0.0", build_tools = ["gleam"], requirements = ["gleam_stdlib", "justin"], source = "local", path = "../formz" },
66+ { name = "gleam_stdlib", version = "0.40.0", build_tools = ["gleam"], requirements = [], otp_app = "gleam_stdlib", source = "hex", outer_checksum = "86606B75A600BBD05E539EB59FABC6E307EEEA7B1E5865AFB6D980A93BCB2181" },
77+ { name = "gleeunit", version = "1.2.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "gleeunit", source = "hex", outer_checksum = "F7A7228925D3EE7D0813C922E062BFD6D7E9310F0BEE585D3A42F3307E3CFD13" },
88+ { name = "justin", version = "1.0.1", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "justin", source = "hex", outer_checksum = "7FA0C6DB78640C6DC5FBFD59BF3456009F3F8B485BF6825E97E1EB44E9A1E2CD" },
99+]
1010+1111+[requirements]
1212+formz = { path = "../formz" }
1313+gleam_stdlib = { version = ">= 0.34.0 and < 2.0.0" }
1414+gleeunit = { version = ">= 1.0.0 and < 2.0.0" }