Rendering partial with a layout
In Rails you might want to wrap a rendered partial with a layout just like you do from your controller.
Did you know render :partial takes a layout option?
render :partial => "shared/touts/pdfs_tout", :layout => "shared/touts/tout_template"
I'm finding this useful.
Written by David Morrow
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Ruby
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#