Class: Spoom::Deadcode::ERB
- Inherits:
-
Erubi::Engine
- Object
- Erubi::Engine
- Spoom::Deadcode::ERB
- Extended by:
- T::Sig
- Defined in:
- lib/spoom/deadcode/erb.rb
Overview
Custom engine to handle ERB templates as used by Rails
Instance Method Summary collapse
-
#initialize(input, properties = {}) ⇒ ERB
constructor
A new instance of ERB.
Constructor Details
#initialize(input, properties = {}) ⇒ ERB
Returns a new instance of ERB.
33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/spoom/deadcode/erb.rb', line 33 def initialize(input, properties = {}) @newline_pending = 0 properties = Hash[properties] properties[:bufvar] ||= "@output_buffer" properties[:preamble] ||= "" properties[:postamble] ||= "#{properties[:bufvar]}.to_s" properties[:escapefunc] = "" super end |