Class: Jekyll::Smartypants

Inherits:
Object
  • Object
show all
Extended by:
MaRuKu::Helpers, MaRuKu::In::Markdown::SpanLevelParser
Defined in:
lib/jekyll/filters.rb,
lib/jekyll/tags/smartypants.rb

Overview

Maruku, inexplicably, offers no way to access its Smartypants implementation outside of the Markdown interface. So here’s a hack.

Class Method Summary collapse

Class Method Details

.educate_string(s) ⇒ Object



87
88
89
# File 'lib/jekyll/filters.rb', line 87

def educate_string(s)
  educate([s]).map{ |x| x.to_html_entity rescue x }.join
end