Skip to content

Commit

Permalink
pull in readme update
Browse files Browse the repository at this point in the history
  • Loading branch information
rkh committed Mar 10, 2013
1 parent a15c1ed commit 32341f1
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions _includes/README.html
Expand Up @@ -2,14 +2,12 @@
<ol class='level-1'> <ol class='level-1'>
<li><a href='#Routes'>Routes</a></li> <li><a href='#Routes'>Routes</a></li>
<li><a href='#Conditions'>Conditions</a></li> <li><a href='#Conditions'>Conditions</a></li>
<li><a href='#Return%20Values'>Return Values</a></li>
<li><a href='#Custom%20Route%20Matchers'>Custom Route Matchers</a></li>
<li><a href='#Static%20Files'>Static Files</a></li>
<li><a href='#Views%20/%20Templates'>Views / Templates</a></li>
<ol class='level-2'> <ol class='level-2'>
<li><a href='#Return%20Values'>Return Values</a></li> <li><a href='#Literal%20Templates'>Literal Templates</a></li>
<li><a href='#Custom%20Route%20Matchers'>Custom Route Matchers</a></li>
<li><a href='#Static%20Files'>Static Files</a></li>
<li><a href='#Views%20/%20Templates'>Views / Templates</a></li>
<ol class='level-3'>
<li><a href='#Literal%20Templates'>Literal Templates</a></li>
</ol>
<li><a href='#Available%20Template%20Languages'>Available Template Languages</a></li> <li><a href='#Available%20Template%20Languages'>Available Template Languages</a></li>
<ol class='level-3'> <ol class='level-3'>
<li><a href='#Haml%20Templates'>Haml Templates</a></li> <li><a href='#Haml%20Templates'>Haml Templates</a></li>
Expand Down Expand Up @@ -262,7 +260,7 @@ <h2>Conditions</h2>
<span class="k">end</span> <span class="k">end</span>
</pre> </pre>
<a name='Return%20Values'></a> <a name='Return%20Values'></a>
<h3>Return Values</h3> <h2>Return Values</h2>


<p>The return value of a route block determines at least the response body passed <p>The return value of a route block determines at least the response body passed
on to the HTTP client, or at least the next middleware in the Rack stack. on to the HTTP client, or at least the next middleware in the Rack stack.
Expand Down Expand Up @@ -295,7 +293,7 @@ <h3>Return Values</h3>
plate and embed the streaming logic in the route.</p> plate and embed the streaming logic in the route.</p>


<a name='Custom%20Route%20Matchers'></a> <a name='Custom%20Route%20Matchers'></a>
<h3>Custom Route Matchers</h3> <h2>Custom Route Matchers</h2>


<p>As shown above, Sinatra ships with built-in support for using String patterns <p>As shown above, Sinatra ships with built-in support for using String patterns
and regular expressions as route matches. However, it does not stop there. You and regular expressions as route matches. However, it does not stop there. You
Expand Down Expand Up @@ -334,7 +332,7 @@ <h3>Custom Route Matchers</h3>
<span class="k">end</span> <span class="k">end</span>
</pre> </pre>
<a name='Static%20Files'></a> <a name='Static%20Files'></a>
<h3>Static Files</h3> <h2>Static Files</h2>


<p>Static files are served from the <code>./public</code> directory. You can specify <p>Static files are served from the <code>./public</code> directory. You can specify
a different location by setting the <code>:public_folder</code> option:</p> a different location by setting the <code>:public_folder</code> option:</p>
Expand All @@ -348,7 +346,7 @@ <h3>Static Files</h3>
<code>Cache-Control</code> header info.</p> <code>Cache-Control</code> header info.</p>


<a name='Views%20/%20Templates'></a> <a name='Views%20/%20Templates'></a>
<h3>Views / Templates</h3> <h2>Views / Templates</h2>


<p>Each template language is exposed via its own rendering method. These <p>Each template language is exposed via its own rendering method. These
methods simply return a string:</p> methods simply return a string:</p>
Expand Down Expand Up @@ -450,7 +448,7 @@ <h3>Views / Templates</h3>
methods will render any strings passed to them directly.</p> methods will render any strings passed to them directly.</p>


<a name='Literal%20Templates'></a> <a name='Literal%20Templates'></a>
<h4>Literal Templates</h4> <h3>Literal Templates</h3>
<pre class="highlight ruby"><span class="n">get</span> <span class="s1">'/'</span> <span class="k">do</span> <pre class="highlight ruby"><span class="n">get</span> <span class="s1">'/'</span> <span class="k">do</span>
<span class="n">haml</span> <span class="s1">'%div.title Hello World'</span> <span class="n">haml</span> <span class="s1">'%div.title Hello World'</span>
<span class="k">end</span> <span class="k">end</span>
Expand Down

0 comments on commit 32341f1

Please sign in to comment.