Sha256: b4b265e4ff2a9d09eb58cc00bf86b81b108fe2fe5ea8321d0217197ee1f8faef

Contents?: true

Size: 481 Bytes

Versions: 22

Compression:

Stored size: 481 Bytes

Contents

#
# tagz.rb allows a safer method of mixin which requires any tagz methods to be
# insider a tagz block - tagz generating methods outside a tagz block with
# raise an error if tagz is included this way.  also notice that the error is
# reported from where it was raised - not from the bowels of the the tagz.rb
# lib.
#

require 'tagz'
include Tagz

puts tagz{
 html_{ 'works only in here' }
}

begin
  html_{ 'not out here' }
rescue Object => e
  p :backtrace => e.backtrace
end

Version data entries

22 entries across 22 versions & 2 rubygems

Version Path
tagz-4.2.0 samples/e.rb
tagz-4.3.0 samples/e.rb