summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--lib/axlsx/workbook/worksheet/worksheet.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/axlsx/workbook/worksheet/worksheet.rb b/lib/axlsx/workbook/worksheet/worksheet.rb
index 68a3e3c6..cdeb524a 100644
--- a/lib/axlsx/workbook/worksheet/worksheet.rb
+++ b/lib/axlsx/workbook/worksheet/worksheet.rb
@@ -193,7 +193,7 @@ module Axlsx
@drawing || @drawing = Axlsx::Drawing.new(self)
end
- # Adds a row to the worksheet and updates auto fit data
+ # Adds a row to the worksheet and updates auto fit data.
# @example - put a vanilla row in your spreadsheet
# ws.add_row [1, 'fish on my pl', '8']
#
@@ -222,6 +222,9 @@ module Axlsx
# @example - force the second cell to be a float value
# ws.add_row [3, 4, 5], :types => [nil, :float]
#
+ # @example - use << alias
+ # ws << [3, 4, 5], :types => [nil, :float]
+ #
# @see Worksheet#column_widths
# @return [Row]
# @option options [Array] values
@@ -235,7 +238,7 @@ module Axlsx
yield @rows.last if block_given?
@rows.last
end
-
+
alias :<< :add_row
# Set the style for cells in a specific row