Hacker News new | ask | show | jobs
by liquidise 4887 days ago
My old company used HAML exclusively for all of our RoR view code. In most general cases it makes the coding faster. THere are of course some wonky edge cases in HAML vs code style best practices.

For instance: try making an html element with a long list of attributes and see how it looks. Or worse, run a translate on a block of text while maintaining reasonable line lengths.

Good? Yes. Silver bullet html replacement? Lol.

1 comments

I've always done html elements with long attribute lists, simply multiline:

    <div attr1="val1, the first one"
         attr2="val2, maybe this one is much longer"
         attr3="you see where I'm going with this"
         attr4="and so on...."
    >
        Div content goes here
    </div>
What do you mean by "run a translate" though?