all repos — markup @ c5f848e82768648571f6e2c45ef18cd121c794f8

The code we use to render README.your_favorite_markup

eager load markdown implementations for fallback
Charlie Somerville charlie@charliesomerville.com
Wed, 04 Dec 2013 10:24:27 +1100
commit

c5f848e82768648571f6e2c45ef18cd121c794f8

parent

9f38d4156f389f31b1741b85e3296191616ec23d

1 files changed, 6 insertions(+), 6 deletions(-)

jump to
M lib/github/markups.rblib/github/markups.rb

@@ -1,21 +1,21 @@

MD_FILES = /md|mkdn?|mdwn|mdown|markdown|litcoffee/ -if markup('github/markdown', MD_FILES) do |content| +if markup('github/markdown', MD_FILES, eager: true) do |content| GitHub::Markdown.render(content) end -elsif markup(:redcarpet, MD_FILES) do |content| +elsif markup(:redcarpet, MD_FILES, eager: true) do |content| RedcarpetCompat.new(content).to_html end -elsif markup(:rdiscount, MD_FILES) do |content| +elsif markup(:rdiscount, MD_FILES, eager: true) do |content| RDiscount.new(content).to_html end -elsif markup(:maruku, MD_FILES) do |content| +elsif markup(:maruku, MD_FILES, eager: true) do |content| Maruku.new(content).to_html end -elsif markup(:kramdown, MD_FILES) do |content| +elsif markup(:kramdown, MD_FILES, eager: true) do |content| Kramdown::Document.new(content).to_html end -elsif markup(:bluecloth, MD_FILES) do |content| +elsif markup(:bluecloth, MD_FILES, eager: true) do |content| BlueCloth.new(content).to_html end end