From ccf221efdfad93e6c035ce59141802303d51e722 Mon Sep 17 00:00:00 2001 From: tobi Date: Thu, 12 Aug 2010 13:51:03 -0700 Subject: [PATCH] Updated Home (textile) --- Home.textile | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Home.textile b/Home.textile index 241bc4e..b30058c 100644 --- a/Home.textile +++ b/Home.textile @@ -5,6 +5,24 @@ Liquid is a template engine which was crafted for very specific requirements * It has to be stateless. The compile and render steps have to be separate, so that the expensive parsing and compiling can be done once; later on, you can just render it by passing in a hash with local variables and objects. * It needs to be able to style emails as well as HTML. +h2. What does it look like? + + source = %| + | + + @template = Liquid::Template.parse(source) + @template.render( 'products' => Product.all ) + + h2. Stuff to read, watch, etc. * [[Liquid for Programmers]]