in my w2tags, I create a macro helper "-li_a",

!H!_li_a
 %li$$ (%a{href='#'} $0%)

%ul
   -li_a.mnu Text1;Text2;Text3

and it will produce tag:
<ul>
   <li class="mnu"><a href='#'>Text1</a></li>
   <li class="mnu"><a href='#'>Text2</a></li>
   <li class="mnu"><a href='#'>Text3</a></li>
</ul>

you can try at: http://w2tags.heroku.com/


On Wed, Dec 9, 2009 at 8:35 PM, JoeE <[email protected]> wrote:
> Hi, I am just checking that the following is the most succinct way of
> creating the following html:
>
> <ul>
>    <li>
>      <a href="#">
>          Text
>
> %ul
>  %li
>    %a{:href => '#'}
>       Text
>
> As a front-ender I am constantly creating links containg blank anchor
> href's.
> The haml ends up looking a lot 'bigger' (taking up a lot of lines
> particularly) in haml than it does in html. As written in html it
> would look like:
>
> <ul>
>         <li><a href="#">Text</a></li>
> </ul>
>
> Thanks
>
> --
>
> You received this message because you are subscribed to the Google Groups 
> "Haml" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/haml?hl=en.
>
>
>



-- 
/wh

e=mc2inhologram

--

You received this message because you are subscribed to the Google Groups 
"Haml" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/haml?hl=en.


Reply via email to