Sha256: 0263feff18a3037957eff21a9d24c0a56f8ff2aacea97daf1cc335b480801e27
Contents?: true
Size: 427 Bytes
Versions: 12
Compression:
Stored size: 427 Bytes
Contents
require 'wikitext' # This allows a us to create a wrapper object similar to those provided by the # Markdown and Textile libraries. It stores the original and formated HTML text # in instance variables. # class WikitextString < String attr_reader :text attr_reader :html def initialize(str) super(str) @text = str.to_s @html = Wikitext::Parser.new.parse(@text) end def to_html @html end end
Version data entries
12 entries across 12 versions & 2 rubygems