What is the Rails 3 way to comment out One Line or Multiple lines of code in a View? And so it doesn't show up in the HTML Source
What is the Rails 3 way to comment out One Line or Multiple lines of code in a View? And so it doesn't show up in the HTML Source
Here's what I do to hide comments from HTML (...whatever, it works!)
def comment
# use this keyword in the views, to comment-out stuff...
end
<h3><% comment = "my Rails-y something something here will not be visible to HTML.
I don't know why I have to comment stuff out in this manner.
It's probably not the 'Rails Way' but ...it works for me.
It would be nice if Rails 3 had some kind of comment-out feature like <%## %> or <%-- --%> or something like that...
Ah, well...
At least they won't be able to 'View Source' and read this comment! ;]
" %></h3>
<h3></h3>
C-YA!