Certainly.

-#
  foo
    bar
  baz

- Nathan

Evgeny wrote:
> Can you nest a huge chunk of "whatever" under a -# ? :)
>
>
> On Dec 10, 2007 6:41 AM, Nathan Weizenbaum <[EMAIL PROTECTED] 
> <mailto:[EMAIL PROTECTED]>> wrote:
>
>
>     But isn't this what -# is for?
>
>     Hampton wrote:
>     > That's pretty cool man.
>     >
>     > Nice use of filters there! That's one area where I'm excited to see
>     > what people come up with in the future.... filters!
>     >
>     > Did you blog about this somewhere?
>     >
>     > -hampton.
>     >
>     > On Dec 9, 2007 6:06 AM, [EMAIL PROTECTED]
>     <mailto:[EMAIL PROTECTED]>
>     > <[EMAIL PROTECTED]
>     <mailto:[EMAIL PROTECTED]>> wrote:
>     >
>     >> When I started using haml, I had bunch of rhtml to convert to haml.
>     >>
>     >> So, I saved rhtml file as haml and started working.
>     >>
>     >> But I was new to haml and most of the files were too long to be
>     >> converted all at once. Also, I didn't like the idea, of making one
>     >> more backup file and move piece by piece to haml file.
>     >>
>     >> And sometimes, when I needed things working quickly, I didn't
>     want to
>     >> convert everything, just some pieces I needed.
>     >>
>     >> Then, I read about filters and decided to implement my own.
>     >>
>     >> It's called nothing filter, because it renders nothing, really
>     handy
>     >> to convert from old rhtml, html or even php. For example:
>     >> ---------------------------------------------------
>     >> %p already converted
>     >>
>     >> :nothing
>     >>   <table>
>     >>   <tr>
>     >>   <td>this is old stuff not yet converted</td></td>
>     >> ---------------------------------------------------
>     >>
>     >> In this way, I can easily test piece by piece for haml errors and
>     >> proper rendering. This is especially usefull for people who are
>     new to
>     >> haml (like me at that time).
>     >>
>     >> So, if you like the idea, you can include it in next version.
>     Change
>     >> is trivial:
>     >> engine.rb:
>     >> ----------------------------------------------------
>     >>    'nothing' => Haml::Filters::Nothing,
>     >> ----------------------------------------------------
>     >> And filters.rb:
>     >> ----------------------------------------------------
>     >>    class Nothing
>     >>       def initialize(text)
>     >>         @text = text
>     >>       end
>     >>       def render
>     >>         ""
>     >>       end
>     >>     end
>     >> ----------------------------------------------------
>     >>
>     >>
>     >
>     > >
>     >
>     >
>
>
>
>
> >


--~--~---------~--~----~------------~-------~--~----~
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