instance method tag_option

Ruby on Rails 4.2.9

Since v3.2.22.5 Last seen in v4.2.9 Private

Available in: v3.2.22.5 v4.0.13 v4.1.16 v4.2.9

Signature

tag_option(key, value, escape)

No documentation comment.

Parameters

key req
value req
escape req
Source
# File actionview/lib/action_view/helpers/tag_helper.rb, line 178
        def tag_option(key, value, escape)
          if value.is_a?(Array)
            value = escape ? safe_join(value, " ") : value.join(" ")
          else
            value = escape ? ERB::Util.unwrapped_html_escape(value) : value.to_s
          end
          %(#{key}="#{value.gsub('"'.freeze, '"'.freeze)}")
        end

Defined in actionview/lib/action_view/helpers/tag_helper.rb line 178 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionView::Helpers::TagHelper

Type at least 2 characters to search.

↑↓ navigate · open · esc close