Sha256: 15159e1e00e756729efe44c3b26255e2c14a4e06a48f3113dc8a24d45b1258e8
Contents?: true
Size: 429 Bytes
Versions: 6
Compression:
Stored size: 429 Bytes
Contents
module Flannel module Wrappable def wrap content, tag, element_id=nil if empty_string?(content) || empty_string?(tag) return content end content.strip! unless tag == "pre" if element_id "<#{tag} id='#{element_id}'>#{content}</#{tag}>" else "<#{tag}>#{content}</#{tag}>" end end def empty_string? str str.nil? || str.strip == "" end end end
Version data entries
6 entries across 6 versions & 1 rubygems