class Temple::Generators::StringBuffer

Implements a string buffer.

_buf = ''
_buf << "static"
_buf << dynamic.to_s
_buf

@api public

Public Instance Methods

on_dynamic(code) click to toggle source
# File lib/temple/generators.rb, line 102
def on_dynamic(code)
  concat("(#{code}).to_s")
end
preamble() click to toggle source
# File lib/temple/generators.rb, line 98
def preamble
  "#{buffer} = ''"
end