Class: Jekyll::Converters::UnorderedList
- Defined in:
- lib/jekyll/converters/cooklang.rb
Instance Method Summary collapse
-
#initialize(items) ⇒ UnorderedList
constructor
A new instance of UnorderedList.
- #to_html ⇒ Object
Methods inherited from ToHTML
Constructor Details
#initialize(items) ⇒ UnorderedList
Returns a new instance of UnorderedList.
73 74 75 |
# File 'lib/jekyll/converters/cooklang.rb', line 73 def initialize(items) @items = items end |
Instance Method Details
#to_html ⇒ Object
77 78 79 80 81 82 |
# File 'lib/jekyll/converters/cooklang.rb', line 77 def to_html list_items = @items.map do |item| item.to_list_item end "<ul>" + list_items.join + "</ul>" end |