Module: Fluffery::Helpers::Includes

Defined in:
lib/fluffery/helpers/includes.rb

Instance Method Summary collapse

Instance Method Details

#ie_conditional(condition, &block) ⇒ Object

Wraps output in IE conditional tags, the condition should be specified in the same format as it would in the conditional itself. For example: ie_conditional(‘lte IE 8’) yields [if lte IE 8]



10
11
12
13
14
15
# File 'lib/fluffery/helpers/includes.rb', line 10

def ie_conditional(condition, &block)
  output = ["<!--[if #{condition}]>"]
  output << capture(&block)
  output << "<![endif]-->"
  output.join("\n").html_safe
end