twilson63 / html2haml

Convert HTML Snippets to Haml
http://html2haml.heroku.com
MIT License
180 stars 82 forks source link

Wierd '?' parsing #11

Open mdda opened 12 years ago

mdda commented 12 years ago

Tested on http://html2haml.heroku.com/

INPUT :

<h3>What People <span>Say</span>?</h3>

OUTPUT:

   %h3
        What People
            = succeed "?" do
                %span Say

But the following is correct (and is generated if the additional space is inserted before '?') :

INPUT :

<h3>What People <span>Say</span> ?</h3>

OUTPUT:

%h3
  What People
  %span Say
  ?
twilson63 commented 12 years ago

Strange I will update to the latest haml gem, and see what happens.

mdda commented 12 years ago

Oh - and just so you know, I came across this when writing something to translate the haml you produce ("real haml") into a dialect that someone has written a clean python parser for (see: https://github.com/Pitmairen/hamlish-jinja)

twilson63 commented 12 years ago

FYI, this is still an issue in the latest html2haml gem