Forked from jonathan-beebe/ruby-rails-erb-comments.erb
Created
October 22, 2018 18:47
-
-
Save wellington1993/defec52deac811372fd686c4ac4824d4 to your computer and use it in GitHub Desktop.
Comment lines in ruby rails html.erb files, as answered on StackOverflow http://stackoverflow.com/a/3901665/123781
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
To comment a single line use | |
<%-# commented line -%> | |
This also works | |
<%# my comment %> | |
To comment a whole block use a if false to surrond your code like this | |
<% if false %> | |
code to comment | |
<% end %> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment