Class: Middleman::Renderers::ERb::Template

Inherits:
Tilt::ErubisTemplate
  • Object
show all
Defined in:
lib/middleman-core/renderers/erb.rb

Instance Method Summary collapse

Instance Method Details

#precompiled_preamble(locals) ⇒ Object

In preamble we need a flag __in_erb_template and SafeBuffer for padrino apps.



13
14
15
16
17
# File 'lib/middleman-core/renderers/erb.rb', line 13

def precompiled_preamble(locals)
  original = super
  "__in_erb_template = true\n" << original
  # .rpartition("\n").first << "#{@outvar} = _buf = ActiveSupport::SafeBuffer.new\n"
end