class Stormy::Content
Public Class Methods
fetch(app, category, key)
click to toggle source
# File lib/stormy/content.rb, line 14 def self.fetch(app, category, key) details = app.cache.content(category,key) do app.store.content(category,key) end self.new(app,details) end
new(app,details)
click to toggle source
Calls superclass method
Stormy::Chunk::new
# File lib/stormy/content.rb, line 3 def initialize(app,details) super(app,details) resolve_content if details[:content] && @template end
Public Instance Methods
render()
click to toggle source
# File lib/stormy/content.rb, line 8 def render @details.merge({ body: @template.render }) end