Module: SC::Helpers::DomIdHelper

Included in:
Builder::Html
Defined in:
lib/sproutcore/helpers/dom_id_helper.rb

Constant Summary collapse

@@tick =
0

Instance Method Summary collapse

Instance Method Details

#dom_id!(type = "id") ⇒ Object



14
15
16
17
# File 'lib/sproutcore/helpers/dom_id_helper.rb', line 14

def dom_id!(type="id")
  @@tick += 1
  return "#{type}_#{(Time.now.to_i + @@tick)}"
end