08 Apr '14, 9am

“How to use Analytics.js to fix your analytics code and achieve metrics nirvana - Pivotal Labs”

“How to use Analytics.js to fix your analytics code and achieve metrics nirvana - Pivotal Labs”

<!-- /app/views/shared/_analytics.html.erb --> <script type="text/javascript"> // Create a queue to push events, and stub all methods window.analytics || (window.analytics = []); window.analytics.methods = ['identify', 'track', 'trackLink', 'trackForm', 'trackClick', 'trackSubmit', 'page', 'pageview', 'ab', 'alias', 'ready', 'group', 'on', 'once', 'off']; window.analytics.factory = function (method) { return function () { var args = Array.prototype.slice.call(arguments); args.unshift(method); window.analytics.push(args); return window.analytics; }; }; for (var i = 0; i < window.analytics.methods.length; i++) { var method = window.analytics.methods[i]; window.analytics[method] = window.analytics.factory(method); } // Set up a way to async load Analytics.js after everything else analytics.load = function(callback) { var script = document.createElement('script'); script.async...

Full article: http://pivotallabs.com/how-to-use-analytics-js-to-fix-you...

Tweets

A few weeks ago, I gave a talk at @pivotallabs ...

pivotallabs.com 07 Apr '14, 6pm

to discuss open companies, giving a short history of the idea as well as some examples of its day-to-day practice. Slides ...

In Rails you can use :disable_with on buttons t...

api.rubyonrails.org 11 Apr '14, 4am

select_tag "people", options_from_collection_for_select(@people, "id", "name") # <select id="people" name="people"><option...

Is "Professional Runner" Code for "Unemployed"?...

flotrack.org 07 Apr '14, 9pm

I know that being a profesh runner is hard, and I respect you for working your butt off and having loads of self-disciplin...

Doing it right via @pivotallabs

pivotallabs.com 15 Apr '14, 4am

Doing it right Nigel Pepper Monday, April 14, 2014 A famous American man called Theodore Roosevelt once wrote: “Nothing in...

Chapter 12: Conversions &amp; Metrics

searchenginejournal.com 06 Apr '14, 4pm

Chapter 12: Conversions & Metrics Metrics are an integral part of a solid SEO strategy. Not only can metrics help you dete...

Cloud Foundry team hiring SREs. Not just DevOps...

pivotallabs.com 10 Apr '14, 12am

The Cloud Foundry engineering team is looking for a few great Site Reliability Engineers (SREs) to join us in running a pl...