Forum: Ruby on Rails partials or helpers: which to use?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
B9a732fc30c32098347a0177c75ee27b?d=identicon&s=25 Jeroen Houben (Guest)
on 2006-04-26 12:18
(Received via mailing list)
Hi,

Just wondering: when do people use a helper and when a partial? I've
just converted a bunch of partials into helpers because I didn't like
the syntax of partials where I can had to pass in a :locals hash every
time. I wonder what advantages a partial has over a helper and vice
versa. I guess a partial has easier access to the controller and various
assigned variables, but I often find a helper cleaner as long as it
doesn't get too big.

I wonder if there are any more performance and/or maintenance issues to
take into account.

Jeroen
This topic is locked and can not be replied to.