Sha256: 0cb2a39b423755c767b6caf8f1629679ea96d90ab31eb38cede9ce5df0ef4b60
Contents?: true
Size: 800 Bytes
Versions: 13
Compression:
Stored size: 800 Bytes
Contents
module Analytical module Base module Api attr_reader :tracking_command_location, :parent, :options attr_accessor :commands def initialize(_parent, _options={}) @parent = _parent @options = _options @tracking_command_location = :body_prepend @commands = [] end def track(*args); ''; end def identify(id, *args); ''; end def event(name, *args); ''; end def init_javascript(location); {}; end def queue(*args) if args.first==:identify @commands.unshift args else @commands << args end end def process_queued_commands command_strings = @commands.collect {|c| send(*c) } @commands = [] command_strings end end end end
Version data entries
13 entries across 13 versions & 1 rubygems