class Volt::TemplateRenderer
Attributes
context[R]
Public Class Methods
new(volt_app, target, context, binding_name, template_name)
click to toggle source
Calls superclass method
Volt::BaseBinding::new
# File lib/volt/page/template_renderer.rb, line 7 def initialize(volt_app, target, context, binding_name, template_name) super(volt_app, target, context, binding_name) @sub_bindings = [] bindings = dom_section.set_content_to_template(volt_app, template_name) bindings.each_pair do |id, bindings_for_id| bindings_for_id.each do |binding| @sub_bindings << binding.call(volt_app, target, context, id) end end end
Public Instance Methods
remove()
click to toggle source
Calls superclass method
Volt::BaseBinding#remove
# File lib/volt/page/template_renderer.rb, line 21 def remove @sub_bindings.each(&:remove) @sub_bindings = [] super end