Walter McGinnis wrote:
On Wed, Oct 21, 2009 at 5:13 AM, Marnen Laibow-Koser
[email protected] wrote:
Srinath A. wrote:
My file contains 5000 lines in which only 1000 lines are custom .
So if use builder i should write by hand all these lines .
In your case, ERb might work better than Builder, or you could use a
Builder partial for the custom stuff.
Here’s an example of using builder (in this case Nokogiri’s flavor)
from within a .erb template as Marmen suggests.
Actually, I was suggesting not using Builder at all, in order that the
3000 static lines could just be part of an ERb file. The ERb could
render the XML without needing Builder. But your approach is very
interesting, and I’ll keep it in mind.
I do have a question, though: what’s the advantage of embedding Builder
in ERb as you did, rather than having the ERb file call a Builder