Class: Faalis::Liquid::RenderTag
- Defined in:
- lib/faalis/liquid/render_tag.rb
Overview
In order to use this class make sure to override the ‘before_render` and implement you logic there, Don’t bother to override the ‘render` method
Instance Attribute Summary
Attributes inherited from Tag
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Tag
argument, #initialize, name, tag_name
Constructor Details
This class inherits a constructor from Faalis::Liquid::Tag
Class Method Details
.view(value) ⇒ Object
9 10 11 12 13 |
# File 'lib/faalis/liquid/render_tag.rb', line 9 def view(value) define_method(:_view) do value end end |
Instance Method Details
#before_render(context) ⇒ Object
16 17 |
# File 'lib/faalis/liquid/render_tag.rb', line 16 def before_render(context) end |
#render(context) ⇒ Object
19 20 21 22 |
# File 'lib/faalis/liquid/render_tag.rb', line 19 def render(context) before_render(context) render_template(context) end |