Skip to content

Commit

Permalink
added markup.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
yayugu committed Nov 1, 2011
1 parent 315798b commit d491c76
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions lib/lokka/markup.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
module Markup
def self.name_description_pair_list
[
['', 'default HTML'],
['kramdown', 'Markdown (Kramdown)'],
['redcloth', 'Textile (Redcloth)']
]
end

def self.use_engine(name, text)
case name
when 'kramdown'
Kramdown::Document.new(text).to_html
when 'redcloth'
RedCloth.new(text).to_html
else
text
end
end
end

0 comments on commit d491c76

Please sign in to comment.