List Info

Thread: crazy idea




crazy idea
country flaguser name
United States
2007-11-07 07:36:43
I know I'll probably get shot down for this (especially so
late in the
day 

I was just looking at my Haml and noticing that I don't use
plain text
nodes that often compared with -, = and %

So in the interests of simplicity and DRYness, would it be a
good idea
to assume that no special character is a tag and use another
control
character for text nodes.

So :

%h1#game_name
%span#users
  = render :partial => "versus", :locals =>
{:game => game}
%ul#user_colors
  %li White
  %li Black

would become

h1#game_name
span#users
  = render :partial => "versus", :locals =>
{:game => game}
ul#user_colors
  li > White
  li > Black

where I've arbitrarily chosen > to mean text node

Fire away

*...(


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Haml" group.
To post to this group, send email to hamlgooglegroups.com
To unsubscribe from this group, send email to
haml-unsubscribegooglegroups.com
For more options, visit this group at http://grou
ps.google.com/group/haml?hl=en
-~----------~----~----~----~------~----~------~--~---


[1]

about | contact  Other archives ( Real Estate discussion Medical topics )