Class: Malt::Format::Tenjin
- Inherits:
-
AbstractTemplate
- Object
- Abstract
- AbstractTemplate
- Malt::Format::Tenjin
- Defined in:
- lib/malt/formats/tenjin.rb
Overview
Tenjin
http://www.kuwata-lab.com/tenjin/
Instance Attribute Summary
Attributes inherited from Abstract
Instance Method Summary collapse
- #html(*data, &content) ⇒ Object
- #rb ⇒ Object
- #to_html(*data, &yld) ⇒ Object
-
#to_rb ⇒ Object
(also: #to_ruby)
Erb templates can be “precompiled” into Ruby templates.
Methods inherited from AbstractTemplate
Methods inherited from Abstract
#default, #engine, engine, extensions, #extensions, #file, file_extension, #file_read, #file_type, #parse_type_from_data, #refile, register, #render, #render_into, #rendering_parameters, #scope_vs_data, #subtype, #text, #to, #to_default, #to_s, #type, #with, #with!
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Malt::Format::AbstractTemplate
Instance Method Details
#html(*data, &content) ⇒ Object
28 29 30 |
# File 'lib/malt/formats/tenjin.rb', line 28 def html(*data, &content) render_into(:html, *data, &content) end |
#rb ⇒ Object
15 16 17 |
# File 'lib/malt/formats/tenjin.rb', line 15 def rb(*) render_engine.compile(text, file) end |