On Thu, Jun 16, 2011 at 9:10 PM, Rob Biedenharn
<[email protected]> wrote:


> Has Rails changed the order in which it does things??
>
> * instantiate a controller object and call the appropriate action method
> * render a view (and its partials, etc)
> * grab the layout and build the page by interpolating the various
> content_for bits and the main render content where there are yield's
> * return the whole thing as the response
>
> How can you get the <head> from the layout first? What if a 'yield
> :head_stuff' is encountered?

That's still how things work in general.

But now you can also ask Rails to stream a certain action, or all
actions of a controller. In that case, a chunked response is produced
and the order of evaluation is different (think top-down). As you
anticipated this has implications, see

http://edgeapi.rubyonrails.org/classes/ActionController/Streaming.html

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to