Flowdock
method

add_default_name_and_id

Importance_0
Ruby on Rails latest stable (v6.1.7.7) - 0 notes - Class: Base
add_default_name_and_id(options) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File actionview/lib/action_view/helpers/tags/base.rb, line 95
          def add_default_name_and_id(options)
            index = name_and_id_index(options)
            options["name"] = options.fetch("name") { tag_name(options["multiple"], index) }

            if generate_ids?
              options["id"] = options.fetch("id") { tag_id(index) }
              if namespace = options.delete("namespace")
                options["id"] = options["id"] ? "#{namespace}_#{options['id']}" : namespace
              end
            end
          end
Register or log in to add new notes.