Sha256: d150caa1604ff0c53ea00f8e580368fbaec0fd8d2f0b49964e6d5e563b050ff7
Contents?: true
Size: 444 Bytes
Versions: 188
Compression:
Stored size: 444 Bytes
Contents
$ ruby bufvar-example.rb ----- default ----- _buf = ''; _buf << %Q`<div>\n` for item in list _buf << %Q` <p>#{ item }</p> <p>#{Erubis::XmlHelper.escape_xml( item )}</p>\n` end _buf << %Q`</div>\n` _buf.to_s ----- with :bufvar option ----- @_out_buf = ''; @_out_buf << %Q`<div>\n` for item in list @_out_buf << %Q` <p>#{ item }</p> <p>#{Erubis::XmlHelper.escape_xml( item )}</p>\n` end @_out_buf << %Q`</div>\n` @_out_buf.to_s
Version data entries
188 entries across 162 versions & 41 rubygems