Module ActionView::Helpers::TagHelper
In: lib/haml/helpers/action_view_mods.rb

Methods

External Aliases

content_tag -> content_tag_without_haml

Public Instance methods

content_tag(name, *args, &block)

[Source]

     # File lib/haml/helpers/action_view_mods.rb, line 99
 99:       def content_tag_with_haml(name, *args, &block)
100:         return content_tag_without_haml(name, *args, &block) unless is_haml?
101: 
102:         preserve = haml_buffer.options[:preserve].include?(name.to_s)
103: 
104:         if block_given? && block_is_haml?(block) && preserve
105:           return content_tag_without_haml(name, *args) {preserve(&block)}
106:         end
107: 
108:         returning content_tag_without_haml(name, *args, &block) do |content|
109:           return Haml::Helpers.preserve(content) if preserve && content
110:         end
111:       end

[Validate]