Thanks to visit codestin.com
Credit goes to github.com

Skip to content

kanigreg/rails-project-63

Repository files navigation

CI HexletCheck

HexletCode

Form generator

Usage

User = Struct.new(:name, :job, :age keyword_init: true)

user = User.new name: 'rob', job: 'hexlet', age: 25

HexletCode.form_for user, url: '#' do |f|
  f.input :name, class: 'user-input'
  f.input :job, as: text, rows: 50, cols: 50
  f.submit
end

# <form action="#" method="post">
#   <label for="name">Name</label>
#   <input type="text" class="user-input" name="name" value="rob">
#   <label for="job">Job</label>
#   <textarea cols="50" rows="50" name="job">hexlet</textarea>
#   <input type="submit" value="Save" name="commit">
# </form>

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published