I am starting to use the Yesod web framework. I have some already existing template HTML code that I would like to automatically translate to a Hamlet code structure. Is there a way to do this?
Here is a solution which might do most of the work
perl -pe 'chomp' test.html | xmllint --format --encode UTF-8 - | perl -pe 's#</[^>]+>##g'
from https://github.com/yesodweb/yesod/wiki/Hamlet
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With