Class: Jekyll::LiquidRenderer::Table
- Inherits:
-
Object
- Object
- Jekyll::LiquidRenderer::Table
- Defined in:
- lib/jekyll/liquid_renderer/table.rb
Instance Method Summary collapse
-
#initialize(stats) ⇒ Table
constructor
A new instance of Table.
- #to_s(n = 50) ⇒ Object
Constructor Details
#initialize(stats) ⇒ Table
Returns a new instance of Table.
3 4 5 |
# File 'lib/jekyll/liquid_renderer/table.rb', line 3 def initialize(stats) @stats = stats end |
Instance Method Details
#to_s(n = 50) ⇒ Object
7 8 9 10 11 |
# File 'lib/jekyll/liquid_renderer/table.rb', line 7 def to_s(n = 50) data = data_for_table(n) widths = table_widths(data) generate_table(data, widths) end |