News for hackers. Stuff that matters.
Re:Rails 3.1 Adopts CoffeeScript, jQuery, Sass and.. Controv... by swilliams on Thursday April 14, 2011 @02:49AM (#2445908)
I tried to like Haml, but every time I've tried it on a semi-complex page it get's way too annoying. I don't think it solves the kind of problems that Sass does.
Re:Rails 3.1 Adopts CoffeeScript, jQuery, Sass and.. Controv... by carbon8 on Thursday April 14, 2011 @03:07AM (#2445950)
In the years I've been using haml my experience has been exactly the opposite. Haml discourages excessive code in the template, reduces noise, makes the document structure immediately obvious and places emphasis on classes, ids, element names and attributes, making it easier to work with CSS and Javascript. As a result, its benefits become even more obvious as templates become larger and more complex.
Re:Rails 3.1 Adopts CoffeeScript, jQuery, Sass and.. Controv... by SupremumLimit on Thursday April 14, 2011 @03:25PM (#2448067)
One useful piece of advice I read about HAML on HN was that it's for structure rather than for content. It gets annoying when you're trying to style words within a paragraph with italic or bold, or when you try to insert a link followed by a period. In those cases, I just use HTML, and the annoyance is gone. Otherwise, I find HAML very useful for reducing visual clutter.