{"id":13427958,"url":"https://github.com/heartcombo/simple_form","last_synced_at":"2026-01-15T22:21:00.095Z","repository":{"id":37624770,"uuid":"451035","full_name":"heartcombo/simple_form","owner":"heartcombo","description":"Forms made easy for Rails! It's tied to a simple DSL, with no opinion on markup.","archived":false,"fork":false,"pushed_at":"2024-08-19T04:11:57.000Z","size":2856,"stargazers_count":8225,"open_issues_count":37,"forks_count":1312,"subscribers_count":157,"default_branch":"main","last_synced_at":"2025-05-06T14:49:57.312Z","etag":null,"topics":["dsl","form-builder","rails","rails-helper","ruby"],"latest_commit_sha":null,"homepage":"http://blog.plataformatec.com.br/tag/simple_form","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/heartcombo.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"MIT-LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2009-12-28T14:23:48.000Z","updated_at":"2025-05-05T16:44:11.000Z","dependencies_parsed_at":"2024-05-01T10:34:17.517Z","dependency_job_id":"c40edc85-661d-445f-8b3f-2d03ffc41ed6","html_url":"https://github.com/heartcombo/simple_form","commit_stats":{"total_commits":1702,"total_committers":302,"mean_commits":5.635761589403973,"dds":0.7679200940070505,"last_synced_commit":"c2c7faf3e532072e1ef511a97d677ae0e7c38957"},"previous_names":["plataformatec/simple_form"],"tags_count":59,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heartcombo%2Fsimple_form","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heartcombo%2Fsimple_form/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heartcombo%2Fsimple_form/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heartcombo%2Fsimple_form/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heartcombo","download_url":"https://codeload.github.com/heartcombo/simple_form/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253354809,"owners_count":21895467,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dsl","form-builder","rails","rails-helper","ruby"],"created_at":"2024-07-31T01:00:43.398Z","updated_at":"2026-01-15T22:21:00.082Z","avatar_url":"https://github.com/heartcombo.png","language":"Ruby","readme":"![Simple Form Logo](https://raw.github.com/heartcombo/simple_form/main/simple_form.png)\n\n[![Gem Version](https://fury-badge.herokuapp.com/rb/simple_form.png)](http://badge.fury.io/rb/simple_form)\n\nRails forms made easy.\n\n**Simple Form** aims to be as flexible as possible while helping you with powerful components to create\nyour forms. The basic goal of **Simple Form** is to not touch your way of defining the layout, letting\nyou find the better design for your eyes. Most of the DSL was inherited from Formtastic,\nwhich we are thankful for and should make you feel right at home.\n\nINFO: This README refers to **Simple Form** 5.0. For older releases, check the related branch for your version.\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n## Table of Contents\n\n- [Installation](#installation)\n  - [Bootstrap](#bootstrap-5)\n  - [Zurb Foundation 5](#zurb-foundation-5)\n  - [Country Select](#country-select)\n- [Usage](#usage)\n  - [Stripping away all wrapper divs](#stripping-away-all-wrapper-divs)\n  - [Collections](#collections)\n  - [Priority](#priority)\n  - [Associations](#associations)\n  - [Buttons](#buttons)\n  - [Wrapping Rails Form Helpers](#wrapping-rails-form-helpers)\n  - [Extra helpers](#extra-helpers)\n    - [Simple Fields For](#simple-fields-for)\n    - [Collection Radio Buttons](#collection-radio-buttons)\n    - [Collection Check Boxes](#collection-check-boxes)\n- [Available input types and defaults for each column type](#available-input-types-and-defaults-for-each-column-type)\n- [Custom inputs](#custom-inputs)\n- [Custom form builder](#custom-form-builder)\n- [I18n](#i18n)\n- [Configuration](#configuration)\n  - [The wrappers API](#the-wrappers-api)\n- [Custom Components](#custom-components)\n- [HTML 5 Notice](#html-5-notice)\n  - [Using non Active Record objects](#using-non-active-record-objects)\n- [Information](#information)\n  - [RDocs](#rdocs)\n  - [Supported Ruby / Rails versions](#supported-ruby--rails-versions)\n  - [Bug reports](#bug-reports)\n- [Maintainers](#maintainers)\n- [License](#license)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n## Installation\n\nAdd it to your Gemfile:\n\n```ruby\ngem 'simple_form'\n```\n\nRun the following command to install it:\n\n```console\nbundle install\n```\n\nRun the generator:\n\n```console\nrails generate simple_form:install\n```\n\n### Bootstrap 5\n\n**Simple Form** can be easily integrated with [Bootstrap 5](http://getbootstrap.com/).\nUse the `bootstrap` option in the install generator, like this:\n\n```console\nrails generate simple_form:install --bootstrap\n```\n\nThis will add an initializer that configures **Simple Form** wrappers for\nBootstrap 5's [form controls](https://getbootstrap.com/docs/5.0/forms/overview/).\nYou have to be sure that you added a copy of the [Bootstrap](http://getbootstrap.com/)\nassets on your application.\n\nFor more information see the generator output, our\n[example application code](https://github.com/heartcombo/simple_form-bootstrap) and\n[the live example app](https://simple-form-bootstrap.herokuapp.com/).\n\n### Zurb Foundation 5\n\nTo generate wrappers that are compatible with [Zurb Foundation 5](http://foundation.zurb.com/), pass\nthe `foundation` option to the generator, like this:\n\n```console\nrails generate simple_form:install --foundation\n```\n\nPlease note that the Foundation wrapper does not support the `:hint` option by default. In order to\nenable hints, please uncomment the appropriate line in `config/initializers/simple_form_foundation.rb`.\nYou will need to provide your own CSS styles for hints.\n\nPlease see the [instructions on how to install Foundation in a Rails app](http://foundation.zurb.com/docs/applications.html).\n\n### Country Select\n\nIf you want to use the country select, you will need the\n[country_select gem](https://rubygems.org/gems/country_select), add it to your Gemfile:\n\n```ruby\ngem 'country_select'\n```\n\nIf you don't want to use the gem you can easily override this behaviour by mapping the\ncountry inputs to something else, with a line like this in your `simple_form.rb` initializer:\n\n```ruby\nconfig.input_mappings = { /country/ =\u003e :string }\n```\n\n## Usage\n\n**Simple Form** was designed to be customized as you need to. Basically it's a stack of components that\nare invoked to create a complete html input for you, which by default contains label, hints, errors\nand the input itself. It does not aim to create a lot of different logic from the default Rails\nform helpers, as they do a great job by themselves. Instead, **Simple Form** acts as a DSL and just\nmaps your input type (retrieved from the column definition in the database) to a specific helper method.\n\nTo start using **Simple Form** you just have to use the helper it provides:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username %\u003e\n  \u003c%= f.input :password %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nThis will generate an entire form with labels for user name and password as well, and render errors\nby default when you render the form with invalid data (after submitting for example).\n\nYou can overwrite the default label by passing it to the input method. You can also add a hint,\nan error, or even a placeholder. For boolean inputs, you can add an inline label as well:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username, label: 'Your username please', error: 'Username is mandatory, please specify one' %\u003e\n  \u003c%= f.input :password, hint: 'No special characters.' %\u003e\n  \u003c%= f.input :email, placeholder: 'user@domain.com' %\u003e\n  \u003c%= f.input :remember_me, inline_label: 'Yes, remember me' %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nIn some cases you may want to disable labels, hints or errors. Or you may want to configure the html\nof any of them:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username, label_html: { class: 'my_class' }, hint_html: { class: 'hint_class' } %\u003e\n  \u003c%= f.input :password, hint: false, error_html: { id: 'password_error' } %\u003e\n  \u003c%= f.input :password_confirmation, label: false %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nIt is also possible to pass any html attribute straight to the input, by using the `:input_html`\noption, for instance:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username, input_html: { class: 'special' } %\u003e\n  \u003c%= f.input :password, input_html: { maxlength: 20 } %\u003e\n  \u003c%= f.input :remember_me, input_html: { value: '1' } %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nIf you want to pass the same options to all inputs in the form (for example, a default class),\nyou can use the `:defaults` option in `simple_form_for`. Specific options in `input` call will\noverwrite the defaults:\n\n```erb\n\u003c%= simple_form_for @user, defaults: { input_html: { class: 'default_class' } } do |f| %\u003e\n  \u003c%= f.input :username, input_html: { class: 'special' } %\u003e\n  \u003c%= f.input :password, input_html: { maxlength: 20 } %\u003e\n  \u003c%= f.input :remember_me, input_html: { value: '1' } %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nSince **Simple Form** generates a wrapper div around your label and input by default, you can pass\nany html attribute to that wrapper as well using the `:wrapper_html` option, like so:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username, wrapper_html: { class: 'username' } %\u003e\n  \u003c%= f.input :password, wrapper_html: { id: 'password' } %\u003e\n  \u003c%= f.input :remember_me, wrapper_html: { class: 'options' } %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nRequired fields are marked with an * prepended to their labels.\n\nBy default all inputs are required. When the form object includes `ActiveModel::Validations`\n(which, for example, happens with Active Record models), fields are required only when there is `presence` validation.\nOtherwise, **Simple Form** will mark fields as optional. For performance reasons, this\ndetection is skipped on validations that make use of conditional options, such as `:if` and `:unless`.\n\nAnd of course, the `required` property of any input can be overwritten as needed:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :name, required: false %\u003e\n  \u003c%= f.input :username %\u003e\n  \u003c%= f.input :password %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nBy default, **Simple Form** will look at the column type in the database and use an\nappropriate input for the column. For example, a column created with type\n`:text` in the database will use a `textarea` input by default. See the section\n[Available input types and defaults for each column\ntype](https://github.com/heartcombo/simple_form#available-input-types-and-defaults-for-each-column-type)\nfor a complete list of defaults.\n\n**Simple Form** also lets you overwrite the default input type it creates:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username %\u003e\n  \u003c%= f.input :password %\u003e\n  \u003c%= f.input :description, as: :text %\u003e\n  \u003c%= f.input :accepts,     as: :radio_buttons %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nSo instead of a checkbox for the *accepts* attribute, you'll have a pair of radio buttons with yes/no\nlabels and a textarea instead of a text field for the description. You can also render boolean\nattributes using `as: :select` to show a dropdown.\n\nIt is also possible to give the `:disabled` option to **Simple Form**, and it'll automatically mark\nthe wrapper as disabled with a CSS class, so you can style labels, hints and other components inside\nthe wrapper as well:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :username, disabled: true, hint: 'You cannot change your username.' %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\n**Simple Form** inputs accept the same options as their corresponding input type helper in Rails:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :date_of_birth, as: :date, start_year: Date.today.year - 90,\n                              end_year: Date.today.year - 12, discard_day: true,\n                              order: [:month, :year] %\u003e\n  \u003c%= f.input :accepts, as: :boolean, checked_value: 'positive', unchecked_value: 'negative' %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nBy default, **Simple Form** generates a hidden field to handle the un-checked case for boolean fields.\nPassing `unchecked_value: false` in the options for boolean fields will cause this hidden field to be omitted,\nfollowing the convention in Rails. You can also specify `include_hidden: false` to skip the hidden field:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :just_the_checked_case, as: :boolean, include_hidden: false %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\n**Simple Form** also allows you to use label, hint, input_field, error and full_error helpers\n(please take a look at the rdocs for each method for more info):\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.label :username %\u003e\n  \u003c%= f.input_field :username %\u003e\n  \u003c%= f.hint 'No special characters, please!' %\u003e\n  \u003c%= f.error :username, id: 'user_name_error' %\u003e\n  \u003c%= f.full_error :token %\u003e\n  \u003c%= f.submit 'Save' %\u003e\n\u003c% end %\u003e\n```\n\nAny extra option passed to these methods will be rendered as html option.\n\n### Stripping away all wrapper divs\n\n**Simple Form** also allows you to strip away all the div wrappers around the `\u003cinput\u003e` field that is\ngenerated with the usual `f.input`.\nThe easiest way to achieve this is to use `f.input_field`.\n\nExample:\n\n```ruby\nsimple_form_for @user do |f|\n  f.input_field :name\n  f.input_field :remember_me, as: :boolean\nend\n```\n\n```html\n\u003cform\u003e\n  ...\n  \u003cinput class=\"string required\" id=\"user_name\" maxlength=\"255\" name=\"user[name]\" size=\"255\" type=\"text\"\u003e\n  \u003cinput name=\"user[remember_me]\" type=\"hidden\" value=\"0\"\u003e\n  \u003clabel class=\"checkbox\"\u003e\n    \u003cinput class=\"boolean optional\" id=\"user_published\" name=\"user[remember_me]\" type=\"checkbox\" value=\"1\"\u003e\n  \u003c/label\u003e\n\u003c/form\u003e\n```\n\nFor check boxes and radio buttons you can remove the label changing `boolean_style` from default value `:nested` to `:inline`.\n\nExample:\n\n```ruby\nsimple_form_for @user do |f|\n  f.input_field :name\n  f.input_field :remember_me, as: :boolean, boolean_style: :inline\nend\n```\n\n```html\n\u003cform\u003e\n  ...\n  \u003cinput class=\"string required\" id=\"user_name\" maxlength=\"255\" name=\"user[name]\" size=\"255\" type=\"text\"\u003e\n  \u003cinput name=\"user[remember_me]\" type=\"hidden\" value=\"0\"\u003e\n  \u003cinput class=\"boolean optional\" id=\"user_remember_me\" name=\"user[remember_me]\" type=\"checkbox\" value=\"1\"\u003e\n\u003c/form\u003e\n```\n\nTo view the actual RDocs for this, check them out here - http://rubydoc.info/github/heartcombo/simple_form/main/SimpleForm/FormBuilder:input_field\n\n### Collections\n\nAnd what if you want to create a select containing the age from 18 to 60 in your form? You can do it\noverriding the `:collection` option:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :user %\u003e\n  \u003c%= f.input :age, collection: 18..60 %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nCollections can be arrays or ranges, and when a `:collection` is given the `:select` input will be\nrendered by default, so we don't need to pass the `as: :select` option. Other types of collection\nare `:radio_buttons` and `:check_boxes`. Those are added by **Simple Form** to Rails set of form\nhelpers (read Extra Helpers section below for more information).\n\nCollection inputs accept two other options beside collections:\n\n* *label_method* =\u003e the label method to be applied to the collection to retrieve the label (use this\n  instead of the `text_method` option in `collection_select`)\n\n* *value_method* =\u003e the value method to be applied to the collection to retrieve the value\n\nThose methods are useful to manipulate the given collection. Both of these options also accept\nlambda/procs in case you want to calculate the value or label in a special way eg. custom\ntranslation. You can also define a `to_label` method on your model as **Simple Form** will search for\nand use `:to_label` as a `:label_method` first if it is found.\n\nBy default, **Simple Form** will use the first item from an array as the label and the second one as the value.\nIf you want to change this behavior you must make it explicit, like this:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :gender, as: :radio_buttons, collection: [['0', 'female'], ['1', 'male']], label_method: :second, value_method: :first %\u003e\n\u003c% end %\u003e\n```\n\nAll other options given are sent straight to the underlying Rails helper(s): [`collection_select`](http://api.rubyonrails.org/classes/ActionView/Helpers/FormOptionsHelper.html#method-i-collection_select), [`collection_check_boxes`](http://api.rubyonrails.org/classes/ActionView/Helpers/FormOptionsHelper.html#method-i-collection_check_boxes), [`collection_radio_buttons`](http://api.rubyonrails.org/classes/ActionView/Helpers/FormOptionsHelper.html#method-i-collection_radio_buttons). For example, you can pass `prompt` and `selected` as:\n\n```ruby\nf.input :age, collection: 18..60, prompt: \"Select your age\", selected: 21\n```\n\nIt may also be useful to explicitly pass a value to the optional `:selected` like above, especially if passing a collection of nested objects.\n\nIt is also possible to create grouped collection selects, that will use the html *optgroup* tags, like this:\n\n```ruby\nf.input :country_id, collection: @continents, as: :grouped_select, group_method: :countries\n```\n\nGrouped collection inputs accept the same `:label_method` and `:value_method` options, which will be\nused to retrieve label/value attributes for the `option` tags. Besides that, you can give:\n\n* *group_method* =\u003e the method to be called on the given collection to generate the options for\n  each group (required)\n\n* *group_label_method* =\u003e the label method to be applied on the given collection to retrieve the label\n  for the _optgroup_ (**Simple Form** will attempt to guess the best one the same way it does with\n  `:label_method`)\n\n### Priority\n\n**Simple Form** also supports `:time_zone` and `:country`. When using such helpers, you can give\n`:priority` as an option to select which time zones and/or countries should be given higher priority:\n\n```ruby\nf.input :residence_country, priority: [ \"Brazil\" ]\nf.input :time_zone, priority: /US/\n```\n\nThose values can also be configured with a default value to be used on the site through the\n`SimpleForm.country_priority` and `SimpleForm.time_zone_priority` helpers.\n\nNote: While using `country_select` if you want to restrict to only a subset of countries for a specific\ndrop down then you may use the `:collection` option:\n\n```ruby\nf.input :shipping_country, priority: [ \"Brazil\" ], collection: [ \"Australia\", \"Brazil\", \"New Zealand\"]\n```\n\n### Associations\n\nTo deal with associations, **Simple Form** can generate select inputs, a series of radios buttons or checkboxes.\nLets see how it works: imagine you have a user model that belongs to a company and `has_and_belongs_to_many`\nroles. The structure would be something like:\n\n```ruby\nclass User \u003c ActiveRecord::Base\n  belongs_to :company\n  has_and_belongs_to_many :roles\nend\n\nclass Company \u003c ActiveRecord::Base\n  has_many :users\nend\n\nclass Role \u003c ActiveRecord::Base\n  has_and_belongs_to_many :users\nend\n```\n\nNow we have the user form:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :name %\u003e\n  \u003c%= f.association :company %\u003e\n  \u003c%= f.association :roles %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nSimple enough, right? This is going to render a `:select` input for choosing the `:company`, and another\n`:select` input with `:multiple` option for the `:roles`. You can, of course, change it to use radio\nbuttons and checkboxes as well:\n\n```ruby\nf.association :company, as: :radio_buttons\nf.association :roles,   as: :check_boxes\n```\n\nThe association helper just invokes `input` under the hood, so all options available to `:select`,\n`:radio_buttons` and `:check_boxes` are also available to association. Additionally, you can specify\nthe collection by hand, all together with the prompt:\n\n```ruby\nf.association :company, collection: Company.active.order(:name), prompt: \"Choose a Company\"\n```\n\nIn case you want to declare different labels and values:\n\n```ruby\nf.association :company, label_method: :company_name, value_method: :id, include_blank: false\n```\n\nPlease note that the association helper is currently only tested with Active Record. It currently\ndoes not work well with Mongoid and depending on the ORM you're using your mileage may vary.\n\n### Buttons\n\nAll web forms need buttons, right? **Simple Form** wraps them in the DSL, acting like a proxy:\n\n```erb\n\u003c%= simple_form_for @user do |f| %\u003e\n  \u003c%= f.input :name %\u003e\n  \u003c%= f.button :submit %\u003e\n\u003c% end %\u003e\n```\n\nThe above will simply call submit. You choose to use it or not, it's just a question of taste.\n\nThe button method also accepts optional parameters, that are delegated to the underlying submit call:\n\n```erb\n\u003c%= f.button :submit, \"Custom Button Text\", class: \"my-button\" %\u003e\n```\n\nTo create a `\u003cbutton\u003e` element, use the following syntax:\n\n```erb\n\u003c%= f.button :button, \"Custom Button Text\" %\u003e\n\n\u003c%= f.button :button do %\u003e\n  Custom Button Text\n\u003c% end %\u003e\n```\n\n### Wrapping Rails Form Helpers\n\nSay you wanted to use a rails form helper but still wrap it in **Simple Form** goodness? You can, by\ncalling input with a block like so:\n\n```erb\n\u003c%= f.input :role do %\u003e\n  \u003c%= f.select :role, Role.all.map { |r| [r.name, r.id, { class: r.company.id }] }, include_blank: true %\u003e\n\u003c% end %\u003e\n```\n\nIn the above example, we're taking advantage of Rails 3's select method that allows us to pass in a\nhash of additional attributes for each option.\n\n### Extra helpers\n\n**Simple Form** also comes with some extra helpers you can use inside rails default forms without relying\non `simple_form_for` helper. They are listed below.\n\n#### Simple Fields For\n\nWrapper to use **Simple Form** inside a default rails form. It works in the same way that the `fields_for`\nRails helper, but change the builder to use the `SimpleForm::FormBuilder`.\n\n```ruby\nform_for @user do |f|\n  f.simple_fields_for :posts do |posts_form|\n    # Here you have all simple_form methods available\n    posts_form.input :title\n  end\nend\n```\n\n#### Collection Radio Buttons\n\nCreates a collection of radio inputs with labels associated (same API as `collection_select`):\n\n```ruby\nform_for @user do |f|\n  f.collection_radio_buttons :options, [[true, 'Yes'], [false, 'No']], :first, :last\nend\n```\n\n```html\n\u003cinput id=\"user_options_true\" name=\"user[options]\" type=\"radio\" value=\"true\" /\u003e\n\u003clabel class=\"collection_radio_buttons\" for=\"user_options_true\"\u003eYes\u003c/label\u003e\n\u003cinput id=\"user_options_false\" name=\"user[options]\" type=\"radio\" value=\"false\" /\u003e\n\u003clabel class=\"collection_radio_buttons\" for=\"user_options_false\"\u003eNo\u003c/label\u003e\n```\n\n#### Collection Check Boxes\n\nCreates a collection of checkboxes with labels associated (same API as `collection_select`):\n\n```ruby\nform_for @user do |f|\n  f.collection_check_boxes :options, [[true, 'Yes'], [false, 'No']], :first, :last\nend\n```\n\n```html\n\u003cinput name=\"user[options][]\" type=\"hidden\" value=\"\" /\u003e\n\u003cinput id=\"user_options_true\" name=\"user[options][]\" type=\"checkbox\" value=\"true\" /\u003e\n\u003clabel class=\"collection_check_box\" for=\"user_options_true\"\u003eYes\u003c/label\u003e\n\u003cinput name=\"user[options][]\" type=\"hidden\" value=\"\" /\u003e\n\u003cinput id=\"user_options_false\" name=\"user[options][]\" type=\"checkbox\" value=\"false\" /\u003e\n\u003clabel class=\"collection_check_box\" for=\"user_options_false\"\u003eNo\u003c/label\u003e\n```\n\nTo use this with associations in your model, you can do the following:\n\n```ruby\nform_for @user do |f|\n  f.collection_check_boxes :role_ids, Role.all, :id, :name # using :roles here is not going to work.\nend\n```\n\nTo add a CSS class to the label item, you can use the `item_label_class` option:\n\n```ruby\nf.collection_check_boxes :role_ids, Role.all, :id, :name, item_label_class: 'my-custom-class'\n```\n\n## Available input types and defaults for each column type\n\nThe following table shows the html element you will get for each attribute\naccording to its database definition. These defaults can be changed by\nspecifying the helper method in the column `Mapping` as the `as:` option.\n\nMapping         | Generated HTML Element               | Database Column Type\n--------------- |--------------------------------------|---------------------\n`boolean`       | `input[type=checkbox]`               | `boolean`\n`string`        | `input[type=text]`                   | `string`\n`citext`        | `input[type=text]`                   | `citext`\n`email`         | `input[type=email]`                  | `string` with `name =~ /email/`\n`url`           | `input[type=url]`                    | `string` with `name =~ /url/`\n`tel`           | `input[type=tel]`                    | `string` with `name =~ /phone/`\n`password`      | `input[type=password]`               | `string` with `name =~ /password/`\n`search`        | `input[type=search]`                 | -\n`uuid`          | `input[type=text]`                   | `uuid`\n`color`         | `input[type=color]`                  | `string`\n`text`          | `textarea`                           | `text`\n`hstore`        | `textarea`                           | `hstore`\n`json`          | `textarea`                           | `json`\n`jsonb`         | `textarea`                           | `jsonb`\n`file`          | `input[type=file]`                   | `string` responding to file methods\n`hidden`        | `input[type=hidden]`                 | -\n`integer`       | `input[type=number]`                 | `integer`\n`float`         | `input[type=number]`                 | `float`\n`decimal`       | `input[type=number]`                 | `decimal`\n`range`         | `input[type=range]`                  | -\n`datetime`      | `datetime select`                    | `datetime/timestamp`\n`date`          | `date select`                        | `date`\n`time`          | `time select`                        | `time`\n`weekday`       | `select` (weekdays as options)       | -\n`select`        | `select`                             | `belongs_to`/`has_many`/`has_and_belongs_to_many` associations\n`radio_buttons` | collection of `input[type=radio]`    | `belongs_to` associations\n`check_boxes`   | collection of `input[type=checkbox]` | `has_many`/`has_and_belongs_to_many` associations\n`country`       | `select` (countries as options)      | `string` with `name =~ /country/`\n`time_zone`     | `select` (timezones as options)      | `string` with `name =~ /time_zone/`\n`rich_text_area`| `trix-editor`                        | -\n\n## Custom inputs\n\nIt is very easy to add custom inputs to **Simple Form**. For instance, if you want to add a custom input\nthat extends the string one, you just need to add this file:\n\n```ruby\n# app/inputs/currency_input.rb\nclass CurrencyInput \u003c SimpleForm::Inputs::Base\n  def input(wrapper_options)\n    merged_input_options = merge_wrapper_options(input_html_options, wrapper_options)\n\n    \"$ #{@builder.text_field(attribute_name, merged_input_options)}\".html_safe\n  end\nend\n```\n\nAnd use it in your views:\n\n```ruby\nf.input :money, as: :currency\n```\nNote, you may have to create the `app/inputs/` directory and restart your webserver.\n\nYou can also redefine existing **Simple Form** inputs by creating a new class with the same name. For\ninstance, if you want to wrap date/time/datetime in a div, you can do:\n\n```ruby\n# app/inputs/date_time_input.rb\nclass DateTimeInput \u003c SimpleForm::Inputs::DateTimeInput\n  def input(wrapper_options)\n    template.content_tag(:div, super)\n  end\nend\n```\n\nOr if you want to add a class to all the select fields you can do:\n\n```ruby\n# app/inputs/collection_select_input.rb\nclass CollectionSelectInput \u003c SimpleForm::Inputs::CollectionSelectInput\n  def input_html_classes\n    super.push('chosen')\n  end\nend\n```\n\nIf needed, you can namespace your custom inputs in a module and tell **Simple Form** to look for\ntheir definitions in this module. This can avoid conflicts with other form libraries (like Formtastic) that look up\nthe global context to find inputs definition too.\n\n```ruby\n# app/inputs/custom_inputs/numeric_input\nmodule CustomInputs\n  class NumericInput \u003c SimpleForm::Inputs::NumericInput\n    def input_html_classes\n      super.push('no-spinner')\n    end\n  end\nend\n```\n\nAnd in the **SimpleForm** initializer :\n\n```ruby\n# config/simple_form.rb\nconfig.custom_inputs_namespaces \u003c\u003c \"CustomInputs\"\n```\n\n## Custom form builder\n\nYou can create a custom form builder that uses **Simple Form**.\n\nCreate a helper method that calls `simple_form_for` with a custom builder:\n\n```ruby\ndef custom_form_for(object, *args, \u0026block)\n  options = args.extract_options!\n  simple_form_for(object, *(args \u003c\u003c options.merge(builder: CustomFormBuilder)), \u0026block)\nend\n```\n\nCreate a form builder class that inherits from `SimpleForm::FormBuilder`.\n\n```ruby\nclass CustomFormBuilder \u003c SimpleForm::FormBuilder\n  def input(attribute_name, options = {}, \u0026block)\n    super(attribute_name, options.merge(label: false), \u0026block)\n  end\nend\n```\n\n## I18n\n\n**Simple Form** uses all power of I18n API to lookup labels, hints, prompts and placeholders. To customize your\nforms you can create a locale file like this:\n\n```yaml\nen:\n  simple_form:\n    labels:\n      user:\n        username: 'User name'\n        password: 'Password'\n    hints:\n      user:\n        username: 'User name to sign in.'\n        password: 'No special characters, please.'\n    placeholders:\n      user:\n        username: 'Your username'\n        password: '****'\n    include_blanks:\n      user:\n        age: 'Rather not say'\n    prompts:\n      user:\n        role: 'Select your role'\n```\n\nAnd your forms will use this information to render the components for you.\n\n**Simple Form** also lets you be more specific, separating lookups through actions.\nLet's say you want a different label for new and edit actions, the locale file would\nbe something like:\n\n```yaml\nen:\n  simple_form:\n    labels:\n      user:\n        username: 'User name'\n        password: 'Password'\n        edit:\n          username: 'Change user name'\n          password: 'Change password'\n```\n\nThis way **Simple Form** will figure out the right translation for you, based on the action being\nrendered. And to be a little bit DRYer with your locale file, you can specify defaults for all\nmodels under the 'defaults' key:\n\n```yaml\nen:\n  simple_form:\n    labels:\n      defaults:\n        username: 'User name'\n        password: 'Password'\n        new:\n          username: 'Choose a user name'\n    hints:\n      defaults:\n        username: 'User name to sign in.'\n        password: 'No special characters, please.'\n    placeholders:\n      defaults:\n        username: 'Your username'\n        password: '****'\n```\n\n**Simple Form** will always look for a default attribute translation under the \"defaults\" key if no\nspecific is found inside the model key.\n\nIn addition, **Simple Form** will fallback to default `human_attribute_name` from Rails when no other\ntranslation is found for labels. Finally, you can also overwrite any label, hint or placeholder\ninside your view, just by passing the option manually. This way the I18n lookup will be skipped.\n\nFor `:prompt` and `:include_blank` the I18n lookup is optional and to enable it is necessary to pass\n`:translate` as value.\n\n```ruby\nf.input :role, prompt: :translate\n```\n\n**Simple Form** also has support for translating options in collection helpers. For instance, given a\nUser with a `:role` attribute, you might want to create a select box showing translated labels\nthat would post either `:admin` or `:editor` as value. With **Simple Form** you could create an input\nlike this:\n\n```ruby\nf.input :role, collection: [:admin, :editor]\n```\n\nAnd **Simple Form** will try a lookup like this in your locale file, to find the right labels to show:\n\n```yaml\nen:\n  simple_form:\n    options:\n      user:\n        role:\n          admin: 'Administrator'\n          editor: 'Editor'\n```\n\nYou can also use the `defaults` key as you would do with labels, hints and placeholders. It is\nimportant to notice that **Simple Form** will only do the lookup for options if you give a collection\ncomposed of symbols only. This is to avoid constant lookups to I18n.\n\nIt's also possible to translate buttons, using Rails' built-in I18n support:\n\n```yaml\nen:\n  helpers:\n    submit:\n      user:\n        create: \"Add %{model}\"\n        update: \"Save Changes\"\n```\n\nThere are other options that can be configured through I18n API, such as required text and boolean.\nBe sure to check our locale file or the one copied to your application after you run\n`rails generate simple_form:install`.\n\nIt should be noted that translations for labels, hints and placeholders for a namespaced model, e.g.\n`Admin::User`, should be placed under `admin_user`, not under `admin/user`. This is different from\nhow translations for namespaced model and attribute names are defined:\n\n```yaml\nen:\n  activerecord:\n    models:\n        admin/user: User\n    attributes:\n        admin/user:\n            name: Name\n```\n\nThey should be placed under `admin/user`. Form labels, hints and placeholders for those attributes,\nthough, should be placed under `admin_user`:\n\n```yaml\nen:\n  simple_form:\n    labels:\n        admin_user:\n            name: Name\n```\n\nThis difference exists because **Simple Form** relies on `object_name` provided by Rails'\nFormBuilder to determine the translation path for a given object instead of `i18n_key` from the\nobject itself. Thus, similarly, if a form for an `Admin::User` object is defined by calling\n`simple_form_for @admin_user, as: :some_user`, **Simple Form** will look for translations\nunder `some_user` instead of `admin_user`.\n\nWhen translating `simple_fields_for` attributes be sure to use the same name you pass to it, e.g. `simple_fields_for :posts` should be placed under `posts` not `post`:\n\n```yaml\nen:\n  simple_form:\n    labels:\n      posts:\n        title: 'Post title'\n    hints:\n      posts:\n        title: 'A good title'\n    placeholders:\n      posts:\n        title: 'Once upon a time...'\n```\n\n## Configuration\n\n**Simple Form** has several configuration options. You can read and change them in the initializer\ncreated by **Simple Form**, so if you haven't executed the command below yet, please do:\n\n`rails generate simple_form:install`\n\n### The wrappers API\n\nWith **Simple Form** you can configure how your components will be rendered using the wrappers API.\nThe syntax looks like this:\n\n```ruby\nconfig.wrappers tag: :div, class: :input,\n                error_class: :field_with_errors,\n                valid_class: :field_without_errors do |b|\n\n  # Form extensions\n  b.use :html5\n  b.optional :pattern\n  b.use :maxlength\n  b.use :placeholder\n  b.use :readonly\n\n  # Form components\n  b.use :label_input\n  b.use :hint,  wrap_with: { tag: :span, class: :hint }\n  b.use :error, wrap_with: { tag: :span, class: :error }\nend\n```\n\nThe _Form components_ will generate the form tags like labels, inputs, hints or errors contents.\nThe available components are:\n\n```ruby\n:label         # The \u003clabel\u003e tag alone\n:input         # The \u003cinput\u003e tag alone\n:label_input   # The \u003clabel\u003e and the \u003cinput\u003e tags\n:hint          # The hint for the input\n:error         # The error for the input\n```\n\nThe _Form extensions_ are used to generate some attributes or perform some lookups on the model to\nadd extra information to your components.\n\nYou can create new _Form components_ using the wrappers API as in the following example:\n\n```ruby\nconfig.wrappers do |b|\n  b.use :placeholder\n  b.use :label_input\n  b.wrapper tag: :div, class: 'separator' do |component|\n    component.use :hint,  wrap_with: { tag: :span, class: :hint }\n    component.use :error, wrap_with: { tag: :span, class: :error }\n  end\nend\n```\n\nthis will wrap the hint and error components within a `div` tag using the class `'separator'`.\n\nYou can customize _Form components_ passing options to them:\n\n```ruby\nconfig.wrappers do |b|\n  b.use :label_input, class: 'label-input-class', error_class: 'is-invalid', valid_class: 'is-valid'\nend\n```\n\nThis sets the input and label classes to `'label-input-class'` and will set the class `'is-invalid'`\nif the input has errors and `'is-valid'` if the input is valid.\n\nIf you want to customize the custom _Form components_ on demand you can give it a name like this:\n\n```ruby\nconfig.wrappers do |b|\n  b.use :placeholder\n  b.use :label_input\n  b.wrapper :my_wrapper, tag: :div, class: 'separator', html: { id: 'my_wrapper_id' } do |component|\n    component.use :hint,  wrap_with: { tag: :span, class: :hint }\n    component.use :error, wrap_with: { tag: :span, class: :error }\n  end\nend\n```\n\nand now you can pass options to your `input` calls to customize the `:my_wrapper` _Form component_.\n\n```ruby\n# Completely turns off the custom wrapper\nf.input :name, my_wrapper: false\n\n# Configure the html\nf.input :name, my_wrapper_html: { id: 'special_id' }\n\n# Configure the tag\nf.input :name, my_wrapper_tag: :p\n```\n\nYou can also define more than one wrapper and pick one to render in a specific form or input.\nTo define another wrapper you have to give it a name, as the follow:\n\n```ruby\nconfig.wrappers :small do |b|\n  b.use :placeholder\n  b.use :label_input\nend\n```\n\nand use it in this way:\n\n```ruby\n# Specifying to whole form\nsimple_form_for @user, wrapper: :small do |f|\n  f.input :name\nend\n\n# Specifying to one input\nsimple_form_for @user do |f|\n  f.input :name, wrapper: :small\nend\n```\n\n**Simple Form** also allows you to use optional elements. For instance, let's suppose you want to use\nhints or placeholders, but you don't want them to be generated automatically. You can set their\ndefault values to `false` or use the `optional` method. Is preferable to use the `optional` syntax:\n\n```ruby\nconfig.wrappers placeholder: false do |b|\n  b.use :placeholder\n  b.use :label_input\n  b.wrapper tag: :div, class: 'separator' do |component|\n    component.optional :hint, wrap_with: { tag: :span, class: :hint }\n    component.use :error, wrap_with: { tag: :span, class: :error }\n  end\nend\n```\n\nBy setting it as `optional`, a hint will only be generated when `hint: true` is explicitly used.\nThe same for placeholder.\n\nIt is also possible to give the option `:unless_blank` to the wrapper if you want to render it only\nwhen the content is present.\n\n```ruby\n  b.wrapper tag: :span, class: 'hint', unless_blank: true do |component|\n    component.optional :hint\n  end\n```\n\n## Custom Components\n\nWhen you use custom wrappers, you might also be looking for a way to add custom components to your\nwrapper. The default components are:\n\n```ruby\n:label         # The \u003clabel\u003e tag alone\n:input         # The \u003cinput\u003e tag alone\n:label_input   # The \u003clabel\u003e and the \u003cinput\u003e tags\n:hint          # The hint for the input\n:error         # The error for the input\n```\n\nA custom component might be interesting for you if your views look something like this:\n\n```erb\n\u003c%= simple_form_for @blog do |f| %\u003e\n  \u003cdiv class=\"row\"\u003e\n    \u003cdiv class=\"span1 number\"\u003e\n      1\n    \u003c/div\u003e\n    \u003cdiv class=\"span8\"\u003e\n      \u003c%= f.input :title %\u003e\n    \u003c/div\u003e\n  \u003c/div\u003e\n  \u003cdiv class=\"row\"\u003e\n    \u003cdiv class=\"span1 number\"\u003e\n      2\n    \u003c/div\u003e\n    \u003cdiv class=\"span8\"\u003e\n      \u003c%= f.input :body, as: :text %\u003e\n    \u003c/div\u003e\n  \u003c/div\u003e\n\u003c% end %\u003e\n```\n\nA cleaner method to create your views would be:\n\n```erb\n\u003c%= simple_form_for @blog, wrapper: :with_numbers do |f| %\u003e\n  \u003c%= f.input :title, number: 1 %\u003e\n  \u003c%= f.input :body, as: :text, number: 2 %\u003e\n\u003c% end %\u003e\n```\n\nTo use the number option on the input, first, tells to Simple Form the place where the components\nwill be:\n\n``` ruby\n# config/initializers/simple_form.rb\nDir[Rails.root.join('lib/components/**/*.rb')].each { |f| require f }\n```\n\nCreate a new component within the path specified above:\n\n```ruby\n# lib/components/numbers_component.rb\nmodule NumbersComponent\n  # To avoid deprecation warning, you need to make the wrapper_options explicit\n  # even when they won't be used.\n  def number(wrapper_options = nil)\n    @number ||= begin\n      options[:number].to_s.html_safe if options[:number].present?\n    end\n  end\nend\n\nSimpleForm.include_component(NumbersComponent)\n```\n\nFinally, add a new wrapper to the config/initializers/simple_form.rb file:\n\n```ruby\nconfig.wrappers :with_numbers, tag: 'div', class: 'row', error_class: 'error' do |b|\n  b.use :html5\n  b.use :number, wrap_with: { tag: 'div', class: 'span1 number' }\n  b.wrapper tag: 'div', class: 'span8' do |ba|\n    ba.use :placeholder\n    ba.use :label\n    ba.use :input\n    ba.use :error, wrap_with: { tag: 'span', class: 'help-inline' }\n    ba.use :hint,  wrap_with: { tag: 'p', class: 'help-block' }\n  end\nend\n```\n\n## HTML 5 Notice\n\nBy default, **Simple Form** will generate input field types and attributes that are supported in HTML5,\nbut are considered invalid HTML for older document types such as HTML4 or XHTML1.0. The HTML5\nextensions include the new field types such as email, number, search, url, tel, and the new\nattributes such as required, autofocus, maxlength, min, max, step.\n\nMost browsers will not care, but some of the newer ones - in particular Chrome 10+ - use the\nrequired attribute to force a value into an input and will prevent form submission without it.\nDepending on the design of the application this may or may not be desired. In many cases it can\nbreak existing UI's.\n\nIt is possible to disable all HTML 5 extensions in **Simple Form** by removing the `html5`\ncomponent from the wrapper used to render the inputs.\n\nFor example, change:\n\n```ruby\nconfig.wrappers tag: :div do |b|\n  b.use :html5\n\n  b.use :label_input\nend\n```\n\nTo:\n\n```ruby\nconfig.wrappers tag: :div do |b|\n  b.use :label_input\nend\n```\n\nIf you want to have all other HTML 5 features, such as the new field types, you can disable only\nthe browser validation:\n\n```ruby\nSimpleForm.browser_validations = false # default is true\n```\n\nThis option adds a new `novalidate` property to the form, instructing it to skip all HTML 5\nvalidation. The inputs will still be generated with the required and other attributes, that might\nhelp you to use some generic javascript validation.\n\nYou can also add `novalidate` to a specific form by setting the option on the form itself:\n\n```erb\n\u003c%= simple_form_for(resource, html: { novalidate: true }) do |form| %\u003e\n```\n\nPlease notice that none of the configurations above will disable the `placeholder` component,\nwhich is an HTML 5 feature. We believe most of the newest browsers are handling this attribute\njust fine, and if they aren't, any plugin you use would take care of applying the placeholder.\nIn any case, you can disable it if you really want to, by removing the placeholder component\nfrom the components list in the **Simple Form** configuration file.\n\nHTML 5 date / time inputs are not generated by **Simple Form** by default, so using `date`,\n`time` or `datetime` will all generate select boxes using normal Rails helpers. We believe\nbrowsers are not totally ready for these yet, but you can easily opt-in on a per-input basis\nby passing the html5 option:\n\n```erb\n\u003c%= f.input :expires_at, as: :date, html5: true %\u003e\n```\n\n## Using non Active Record objects\n\nThere are few ways to build forms with objects that don't inherit from Active Record, as\nfollows:\n\nYou can include the module `ActiveModel::Model`.\n\n```ruby\nclass User\n  include ActiveModel::Model\n\n  attr_accessor :id, :name\nend\n```\n\nIf you are using Presenters or Decorators that inherit from `SimpleDelegator` you can delegate\nit to the model.\n\n```ruby\nclass UserPresenter \u003c SimpleDelegator\n  # Without that, Simple Form will consider the user model as the object.\n  def to_model\n    self\n  end\nend\n```\n\nYou can define all methods required by the helpers.\n\n```ruby\nclass User\n  extend ActiveModel::Naming\n\n  attr_accessor :id, :name\n\n  def to_model\n    self\n  end\n\n  def to_key\n    id\n  end\n\n  def persisted?\n    false\n  end\nend\n```\n\nTo have SimpleForm infer the attributes' types, you can provide\n`#has_attribute?` and `#type_for_attribute` methods.\nThe later should return an object that responds to `#type`\nwith the attribute type. This is useful for generating\nthe correct input types (eg: checkboxes for booleans).\n\n```ruby\nclass User \u003c Struct.new(:id, :name, :age, :registered)\n  def to_model\n    self\n  end\n\n  def model_name\n    OpenStruct.new(param_key: \"user\")\n  end\n\n  def to_key\n    id\n  end\n\n  def persisted?\n    id.present?\n  end\n\n  def has_attribute?(attr_name)\n    %w(id name age registered).include?(attr_name.to_s)\n  end\n\n  def type_for_attribute(attr_name)\n    case attr_name.to_s\n      when \"id\" then OpenStruct.new(type: :integer)\n      when \"name\" then OpenStruct.new(type: :string)\n      when \"age\" then OpenStruct.new(type: :integer)\n      when \"registered\" then OpenStruct.new(type: :boolean)\n    end\n  end\nend\n```\n\nIf your object doesn't implement those methods, you must make explicit it when you are\nbuilding the form\n\n```ruby\nclass User\n  attr_accessor :id, :name\n\n  # The only method required to use the f.submit helper.\n  def persisted?\n    false\n  end\nend\n```\n\n```erb\n\u003c%= simple_form_for(@user, as: :user, method: :post, url: users_path) do |f| %\u003e\n  \u003c%= f.input :name %\u003e\n  \u003c%= f.submit 'New user' %\u003e\n\u003c% end %\u003e\n```\n\n## Information\n\n### RDocs\n\nYou can view the **Simple Form** documentation in RDoc format here:\n\nhttp://rubydoc.info/github/heartcombo/simple_form/main/frames\n\n### Supported Ruby / Rails versions\n\nWe intend to maintain support for all Ruby / Rails versions that haven't reached end-of-life.\n\nFor more information about specific versions please check [Ruby](https://www.ruby-lang.org/en/downloads/branches/)\nand [Rails](https://guides.rubyonrails.org/maintenance_policy.html) maintenance policies, and our test matrix.\n\n### Bug reports\n\nIf you discover any bugs, feel free to create an issue on GitHub. Please add as much information as\npossible to help us in fixing the potential bug. We also encourage you to help even more by forking and\nsending us a pull request.\n\nhttps://github.com/heartcombo/simple_form/issues\n\nIf you have discovered a security related bug, please do NOT use the GitHub issue tracker. Send an e-mail to heartcombo.oss@gmail.com.\n\n## License\n\nMIT License.\nCopyright 2020-2025 Rafael França, Carlos Antonio da Silva.\nCopyright 2009-2019 Plataformatec.\n\nThe Simple Form logo is licensed under [Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License](https://creativecommons.org/licenses/by-nc-nd/4.0/).\n","funding_links":[],"categories":["View Helper","Ruby","Uncategorized","Form Builder","Forms","Gems"],"sub_categories":["Omniauth","Uncategorized","Articles"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheartcombo%2Fsimple_form","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheartcombo%2Fsimple_form","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheartcombo%2Fsimple_form/lists"}