Sha256: be1a921315239e44296c9a8138ba3eed6d4df96a576b1b9c1a90af8e8ecaf5e8
Contents?: true
Size: 410 Bytes
Versions: 4
Compression:
Stored size: 410 Bytes
Contents
module Awestruct module Hamlable def render(context) rendered = '' begin haml_engine = Haml::Engine.new( raw_page_content ) rendered = haml_engine.render( context ) rescue => e puts e puts e.backtrace end rendered end def content context = OpenStruct.new( :site=>site, :page=>self ) render( context ) end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
awestruct-0.0.4 | lib/awestruct/hamlable.rb |
awestruct-0.0.3 | lib/awestruct/hamlable.rb |
awestruct-0.0.2 | lib/awestruct/hamlable.rb |
awestruct-0.0.1 | lib/awestruct/hamlable.rb |