Sha256: 72d37d87968754f7a0d0b0ef4d63bf3c0b904fd55ea20e1a7d656d1a00f7b038

Contents?: true

Size: 207 Bytes

Versions: 6

Compression:

Stored size: 207 Bytes

Contents

module SproutCore
  module Helpers

    module DomIdHelper
      @@tick = 0

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

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
sproutcore-0.9.18 lib/sproutcore/helpers/dom_id_helper.rb
sproutcore-0.9.19 lib/sproutcore/helpers/dom_id_helper.rb
sproutcore-0.9.23 lib/sproutcore/helpers/dom_id_helper.rb
sproutcore-0.9.22 lib/sproutcore/helpers/dom_id_helper.rb
sproutcore-0.9.20 lib/sproutcore/helpers/dom_id_helper.rb
sproutcore-0.9.21 lib/sproutcore/helpers/dom_id_helper.rb