hamlphp / HamlPHP

Yet another Haml to HTML converter written in PHP.
http://hamlphp.github.com/HamlPHP
MIT License
84 stars 15 forks source link

HamlPHP renders wrongly indented HTML #15

Closed complex64 closed 8 years ago

complex64 commented 12 years ago
- if ($image != null)
  %img{:src => $image}
- else
  Image not found

Should render to:

<img src="..."></img>

Instead it renders to:

  <img  src="..."></img>

The snippet not only bears the original indentation but additionally HamlPHP introduces two white-spaces between the img tag and its src attribute.

svallory commented 12 years ago

Rendered html "beauty" isn't really a big concern. As in most of the time you won't be editing the generated html/php. I'll leave it open though and fix it after finishing other planned features.