Sha256: 2fb993db1138a6c3577f9cb38a3cb59ce705a04f9ddf5076b905c1a6785a697b
Contents?: true
Size: 584 Bytes
Versions: 5
Compression:
Stored size: 584 Bytes
Contents
require 'reverse_markdown/version' require 'reverse_markdown/mapper' require 'reverse_markdown/errors' require 'nokogiri' module ReverseMarkdown def self.parse(input, opts={}) root = case input when String then Nokogiri::HTML(input).root when Nokogiri::XML::Document then input.root when Nokogiri::XML::Node then input end ReverseMarkdown::Mapper.new(opts).process_root(root) end # 2012/08/11 joe: possibly deprecate in favour of #parse class << self alias parse_string parse alias parse_element parse end end
Version data entries
5 entries across 5 versions & 1 rubygems