|
12 | 12 | <link href="//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.min.css" rel="stylesheet"> |
13 | 13 | <link href="/main.css" rel="stylesheet" type="text/css"> |
14 | 14 |
|
15 | | - <script class="js-allow-in-head" src="//use.typekit.net/txx2jfv.js"></script> |
16 | | - <script class="js-allow-in-head">try{Typekit.load();}catch(e){}</script> |
| 15 | + <script class="js-allow-before-footer" src="//use.typekit.net/txx2jfv.js"></script> |
| 16 | + <script class="js-allow-before-footer">try{Typekit.load();}catch(e){}</script> |
17 | 17 |
|
18 | | - |
19 | | - <script id="ga-setup"> |
| 18 | + <script class="js-allow-before-footer"> |
20 | 19 | // Google Analytics async snippet: |
21 | 20 | // http://goo.gl/3FPNDx |
22 | 21 | window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date; |
| 22 | + ga('create', 'UA-21292978-1', 'auto'); |
23 | 23 |
|
24 | | - // In non-production mode, simply log GA hits to the console. |
25 | | - // Note, tasks must be set before sending the first hit |
26 | | - ga(function(tracker) { |
27 | | - tracker.set('sendHitTask', function() { |
28 | | - // Throw to stop subsequent tasks. |
29 | | - throw 'Abort tracking in non-production environments.' |
| 24 | + {% if env == 'dev' %} |
| 25 | + // In non-production mode, simply log GA hits to the console. |
| 26 | + // Note, tasks must be set before sending the first hit |
| 27 | + ga(function(tracker) { |
| 28 | + tracker.set('sendHitTask', function() { |
| 29 | + // Throw to stop subsequent tasks. |
| 30 | + throw 'Abort tracking in non-production environments.' |
| 31 | + }); |
30 | 32 | }); |
31 | | - }); |
32 | | - |
33 | | - // Create the GA tracker before doing any logging. |
34 | | - ga('create', 'UA-21292978-1', 'auto'); |
| 33 | + {% endif %} |
35 | 34 | </script> |
36 | | - |
37 | | - <script async src="//www.google-analytics.com/analytics-debug.js"></script> |
38 | | - |
39 | 35 | </head> |
0 commit comments