Method: Nokogiri::XML::Node#write_xml_to

Defined in:
lib/nokogiri/xml/node.rb

#write_xml_to(io, options = {}) ⇒ Object

Write Node as XML to io with options

doc.write_xml_to io, :encoding => 'UTF-8'

See Node#write_to for a list of options


1487
1488
1489
1490
# File 'lib/nokogiri/xml/node.rb', line 1487

def write_xml_to(io, options = {})
  options[:save_with] ||= SaveOptions::DEFAULT_XML
  write_to(io, options)
end