mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
Updating README for :layout => true.
This commit is contained in:
parent
b26df9ae95
commit
578bbabd82
1 changed files with 7 additions and 0 deletions
|
@ -189,6 +189,13 @@ method:
|
|||
haml :index
|
||||
end
|
||||
|
||||
Some times you'll want to render a specific template with or without a
|
||||
layout based on whether the request is Ajax or not:
|
||||
|
||||
get '/' do
|
||||
haml :index, :layout => !request.xhr?
|
||||
end
|
||||
|
||||
== Helpers
|
||||
|
||||
The top-level <tt>helpers</tt> method
|
||||
|
|
Loading…
Reference in a new issue