class Phlex::SGML

def render(renderable, &block)

Returns:
  • (nil) -

Parameters:
  • renderable (Phlex::SGML) --
def render(renderable, &block)
	case renderable
	when Phlex::SGML
		renderable.call(target: @_target, view_context: @_view_context, parent: self, &block)
	when Class
		if renderable < Phlex::SGML
			renderable.new.call(target: @_target, view_context: @_view_context, parent: self, &block)
		end
	else
		raise ArgumentError, "You can't render a #{renderable}."
	end
	nil
end