how about preserve rather than find_and_preserve. i'm not sure that the find bit is particularily useful ? preserve is nice and short and straight to the point . or does it clash with :preserve ?
Can we list all situations where we commonly use preserve? Is it restricted to only textarea and pre ? Or are their other (common) reasons? weepy On Feb 12, 2:08 am, Hampton <[EMAIL PROTECTED]> wrote: > Every site I build uses it at least 2-4 times. > > -hampton. > > On 2/11/07, Jeff <[EMAIL PROTECTED]> wrote: > > > > > I don't know about preloading whitespace, but typing newlines into a > > textarea is terribly common. Every blog in the universe does it. > > This message board does it. > > > JR > > > On Feb 11, 7:17 pm, Nathan Weizenbaum <[EMAIL PROTECTED]> wrote: > > > Preloading a textarea with whitespace-sensitive content is not terribly > > > common. But the point is that no matter the degree of its commonness, > > > it's a special case, and handling special cases is something that > > > shouldn't be done by default. It's inefficient, leads to feature bloat, > > > could make for nasty surprises, and causes the documentation to get very > > > tangled very quickly. > > > > "~" is more obscure than "%" or "-" because it's not commonly used. The > > > largest number of questions I heard about Haml when it was first > > > released were, "I get =, but what does ~ do?" For a long time we've been > > > getting people saying "My whitespace doesn't work!" Even though this > > > command is fully documented in the reference, people didn't know it > > > existed. The difference between "%" and "-" is that both of those are > > > fundamental to the functionality of Haml... "~" was not. > > > > By changing it to find_and_preserve, we've done two things. First, we've > > > linked it into the existing Helper functionality, which is (hopefully) a > > > place people look for solutions to these problems. Second, we've made > > > the name very descriptive, unlike "~", which doesn't convey any meaning > > > at all. > > > > - Nathan > > > > Jeff wrote: > > > > Nathan, > > > > > IMHO, textarea is not a "case that doesn't come up at all for most > > > > people". It comes up for everyone who creates a form. > > > > > Ross argues for maintaining the integrity of haml the template > > > > langauge. When I suggested special behavior for textarea and pre, I > > > > was arguing for maintaining the integrity of the markup that haml > > > > produces. > > > > > I love haml and I can live with the deprecation, but I don't buy the > > > > arguments. ~ is no more obscure than %, - or find_and_preserve. > > > > > -- Jeff --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
