Tuesday, July 15th, 2008
Pass Blocks to Your Markdown Helper
For the new site, I’m going to be using Markdown to handle the formatting of all of my content. I created a simple helper to make things easy:
def markdown(str) RDiscount.new(str).to_html end
(Note: I’m using the RDiscount library instead of BlueCloth, for reasons discussed here)
However, what if I wanted to add a “Read more” link at [...]