Sha256: e1b2a6a768f3fe18a7062a2ce72771d341df1c19ce9e787583bd264fa08761d8
Contents?: true
Size: 412 Bytes
Versions: 9
Compression:
Stored size: 412 Bytes
Contents
class ESV::Generator def initialize @data_rows = [] end def <<(row) @data_rows << row end def render book = Spreadsheet::Workbook.new sheet = book.create_worksheet @data_rows.each_with_index do |data_row, index| row = sheet.row(index) row.push(*data_row) end content = "" fake_file = StringIO.new(content) book.write(fake_file) content end end
Version data entries
9 entries across 9 versions & 1 rubygems