diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-09-16 11:14:28 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-09-16 11:14:28 -0300 |
commit | 1bdb233bc22cbd2e557d2e0ccca21f04b15eb65a (patch) | |
tree | 7df529adbb5fa1d3a99fca50199c02fbfc0c48c1 | |
parent | 6e4aa9d5eab53bb0f5063145f5143d91a175a1f7 (diff) | |
parent | 700ec897f97c60016ad748236bf3a49ef15a20de (diff) | |
download | rails-1bdb233bc22cbd2e557d2e0ccca21f04b15eb65a.tar.gz rails-1bdb233bc22cbd2e557d2e0ccca21f04b15eb65a.tar.bz2 rails-1bdb233bc22cbd2e557d2e0ccca21f04b15eb65a.zip |
Merge pull request #16790 from cirosantilli/explain-erb-space-removal
Explain ERB space removal.
[ci skip]
-rw-r--r-- | actionview/lib/action_view/base.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/actionview/lib/action_view/base.rb b/actionview/lib/action_view/base.rb index d1bade0d3d..3071a13655 100644 --- a/actionview/lib/action_view/base.rb +++ b/actionview/lib/action_view/base.rb @@ -33,7 +33,9 @@ module ActionView #:nodoc: # # If you absolutely must write from within a function use +concat+. # - # <%- and -%> suppress leading and trailing whitespace, including the trailing newline, and can be used interchangeably with <% and %>. + # When on a line that only contains whitespaces except for the tag, <% %> suppress leading and trailing whitespace, + # including the trailing newline. <% %> and <%- -%> are the same. + # Note however that <%= %> and <%= -%> are different: only the latter removes trailing whitespaces. # # === Using sub templates # |