Partials or helpers: which to use?

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 forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs