module Haml::Flatrack::ViewAdditions::TagHelper
Public Instance Methods
html_tag_with_haml(name, *args, &block)
click to toggle source
# File lib/haml/flatrack/view_additions/tag_helper.rb, line 9 def html_tag_with_haml(name, *args, &block) return html_tag_without_haml(name, *args, &block) unless is_haml? preserve = haml_buffer.options[:preserve].include?(name.to_s) if block_given? && block_is_haml?(block) && preserve return html_tag_without_haml(name, *args) { preserve(&block) } end content = html_tag_without_haml(name, *args, &block) content = preserve(content) if preserve && content content end