Class: LexxyVariables::Renderers::Substitution
- Inherits:
-
Object
- Object
- LexxyVariables::Renderers::Substitution
- Defined in:
- lib/lexxy_variables/renderers/substitution.rb
Overview
Default renderer. Looks each key up in the assigns hash, no template engine, so author-typed text can never be interpreted as code. The value is returned raw: the resolver injects it as a DOM text node, where HTML serialization escapes it and plain-text/markdown conversions read it as-is.
Instance Method Summary collapse
Instance Method Details
#resolve_value(key, assigns) ⇒ Object
8 9 10 |
# File 'lib/lexxy_variables/renderers/substitution.rb', line 8 def resolve_value(key, assigns) assigns[key].to_s end |