Best way to add comments in erb

Kalyan Maddu picture Kalyan Maddu · May 5, 2010 · Viewed 80.1k times · Source

How do we add comments in erb files, if we do not want them to be generated into the html content?

Answer

John Douthat picture John Douthat · May 5, 2010

Use the <%# %> sequence, e.g.

<%# This is a great comment! %>