Thanks!

I did adapt same approach, with moving all drag-n-drop wiring into the
helpers.

I did try the using pipes originally, but that didn't work and I
inferred pipes only work for markup, but not the ruby code.  Is it not
the case?

On Jun 19, 11:13 pm, Nathan Weizenbaum <[EMAIL PROTECTED]> wrote:
> Yes, but we advise against it. The nicest way to deal with that is to
> refactor the code a bit and move the giant function call to its own
> helper. This improves readability. For example,
>
> # foos_helper.rb
> def origin_input_reciever
>
>   drop_receiving_element(:origin_input,
>                          :accept=>[:font_chooser,:size_chooser],
>                          :hoverclass => 'accept_drop')
>
> end
>
> -# index.haml
> = origin_input_reciever
>
> However, if you absolutely *must* include it in the Haml, you can add a
> pipe character ("|") to the end of each line:
>
> = drop_receiving_element(:origin_input,       |
>       :accept=>[:font_chooser,:size_chooser], |
>       :hoverclass => 'accept_drop')           |
>
> - Nathan
>
> pingva wrote:
> > Hi,
>
> > I greatly enjoy using haml & sass, but recently ran into this issue:
>
> > I have many lines like this:
>
> > =
> > drop_receiving_element(:origin_input, 
> > :accept=>[:font_chooser,:size_chooser], :hoverclass
> > => 'accept_drop')
>
> > and it is going to get even longer.  I'd like to wrap it so it looks
> > something like this:
>
> > = drop_receiving_element(:origin_input,
> >       :accept=>[:font_chooser,:size_chooser],
> >       :hoverclass => 'accept_drop')
>
> > is there a way to do that?
>
> > 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to