I'm trying to use a block in a helper,
but that's giving me this error:
SyntaxError - syntax error, unexpected ')'
...rbout.concat(( green_title do ).to_s); _erbout.concat "\n ...
... ^
(erb):4254: syntax error, unexpected end-of-input, expecting ')'
; _erbout.force_encoding(__ENCODING__)
^:
(erb):1649:in `'
here's how I'm calling it:
<%= green_title do %>
text
<% end %>
and here's my helper:
def green_title(&block)
capture do
concat content_tag(:h3) do
yeld
end
end
end