Commit bb1d00c8 authored by Ricardo J. Mendez's avatar Ricardo J. Mendez

Trivial analytics integration

parent ad3aad95
......@@ -20,6 +20,10 @@
<link href="http://maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">
<link href='http://fonts.googleapis.com/css?family=Roboto:400,700,300' rel='stylesheet' type='text/css'>
<link href="pe-icon-7-stroke.css" rel="stylesheet"/>
<!-- Google Analytics -->
<script type="text/javascript" src="init-analytics.js"></script>
<!-- End Google Analytics -->
</head>
<body>
......
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-6610761-4', 'auto');
ga('set', 'appName','Relevance-WebApp');
ga('set', 'checkProtocolTask', function(){});
ga('send', 'screenview', {screenName: "intro"});
......@@ -30,5 +30,6 @@
"js": ["content.js"]
}
],
"content_security_policy": "script-src 'self' https://www.google-analytics.com; object-src 'self'",
"manifest_version": 2
}
\ No newline at end of file
......@@ -58,6 +58,7 @@
(register-handler
:app-state-item
(fn [app-state [_ path item]]
(js/ga "send" "screenview" #js {:screenName (name item)})
(assoc-in app-state path item)))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment