Module: Webgen::ContentProcessor::Erb
- Extended by:
- ERB::Util
- Defined in:
- lib/webgen/content_processor/erb.rb
Overview
Processes embedded Ruby statements.
Class Method Summary collapse
-
.call(context) ⇒ Object
Process the Ruby statements embedded in the content of
context
.
Class Method Details
.call(context) ⇒ Object
Process the Ruby statements embedded in the content of context
.
15 16 17 18 19 20 |
# File 'lib/webgen/content_processor/erb.rb', line 15 def self.call(context) erb = ERB.new(context.content, nil, context.website.config['content_processor.erb.trim_mode']) erb.filename = context.ref_node.alcn context.content = erb.result(binding) context end |