Module: RenderTable::Options

Defined in:
lib/render_table/options.rb

Class Method Summary collapse

Class Method Details

.generate(table, template, record, index) ⇒ Object



2
3
4
5
# File 'lib/render_table/options.rb', line 2

def self.generate(table, template, record, index)
  template = File.read(template) if File.exist? template
  ERB.new(template, 0, '%<>').result(binding)
end