class Phlex::SGML
def render(renderable, &block)
-
(nil)
-
Parameters:
-
renderable
(Phlex::SGML
) --
def render(renderable, &block) case renderable when Phlex::SGML renderable.call(context: @_context, view_context: @_view_context, parent: self, &block) when Class if renderable < Phlex::SGML renderable.new.call(context: @_context, view_context: @_view_context, parent: self, &block) end when Enumerable renderable.each { |r| render(r, &block) } when Proc yield_content(&renderable) else raise ArgumentError, "You can't render a #{renderable}." end nil end