why adding a simple div to HAML will break the code?
it is quite strange that the following works:
- 1.upto(30) do |i|
= i
%br
but the following won't:
%div this line
- 1.upto(30) do |i|
= i
%br
Isn't the second part 开发者_运维问答just to add a div and let the numbers go into that div?
Was the this line
part intended? Or are you indicating the error position? Because without it, the snippit works.
If this line
is supposed to be content, then what you want is probably:
%div
this line
- 1.upto(30) do |i|
= i
%br
精彩评论