Module: ArticleJSON::Export::Common::HTML::Elements::List
- Defined in:
- lib/article_json/export/common/html/elements/list.rb
Instance Method Summary collapse
-
#export ⇒ Nokogiri::XML::NodeSet
Generate the list node with its elements.
Instance Method Details
#export ⇒ Nokogiri::XML::NodeSet
Generate the list node with its elements
9 10 11 12 13 14 15 16 17 18 |
# File 'lib/article_json/export/common/html/elements/list.rb', line 9 def export create_element(tag_name) do |list| @element.content.each do |child_element| list_item_wrapper = create_element(:li) do |item| item.add_child(paragraph_exporter.new(child_element).export) end list.add_child(list_item_wrapper) end end end |