Class: Redcarpet::Render::SeeingIsBelieving::Enricher
- Inherits:
-
Object
- Object
- Redcarpet::Render::SeeingIsBelieving::Enricher
- Defined in:
- lib/redcarpet/render/seeing_is_believing/enricher.rb
Instance Method Summary collapse
-
#initialize(options = Options.new) ⇒ Enricher
constructor
A new instance of Enricher.
- #process(code) ⇒ Object
Constructor Details
Instance Method Details
#process(code) ⇒ Object
12 13 14 15 16 17 |
# File 'lib/redcarpet/render/seeing_is_believing/enricher.rb', line 12 def process(code) code.split("\n"). zip(evaluate_code(code)). map(&combine_code_with_result). join("\n") end |