Created
September 18, 2013 02:45
-
-
Save siruguri/6603806 to your computer and use it in GitHub Desktop.
Redcarpet test code for footnotes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'redcarpet' | |
def test_that_footnotes_work | |
markdown = <<MD | |
This is a footnote.[^1] | |
[^1]: It provides additional information. | |
MD | |
renderer = Redcarpet::Markdown.new(Redcarpet::Render::HTML, :footnotes => true) | |
output = renderer.render(markdown) | |
puts output | |
end | |
test_that_footnotes_work |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment