Class: Jv::Handler
- Inherits:
-
Object
- Object
- Jv::Handler
- Defined in:
- lib/jv/handler.rb
Class Method Summary collapse
Class Method Details
.call(template) ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'lib/jv/handler.rb', line 8 def self.call(template) <<~SRC r ||= Jv::Render.new(self) _partial ||= nil hash = ->{ #{template.source} }.() _partial.nil? ? hash.to_json : "\#{hash.to_json}," SRC end |