Rails 2.2.2
_competition.html.erb
<p>This is packed</p>
<% pack do %>
// some javascript
<% end %>
competitions_helper.rb
def pack(&block)
yield + 'PACKED'
end
However 'PACKED' does not get appended to my javascript string, its as if pack do
has no effect. It seems like there is some oddness going off with context of the blocks and the actual view rendering because if I remove the call to yield in the helper and return a hard coded string I get no output from pack.