Skip to content

Commit a60bdf6

Browse files
author
Steve Krouse
committed
refactor analytics to _includes
1 parent 2be3136 commit a60bdf6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+57
-607
lines changed

_includes/analytics.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{% include analytics.html %}

about.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -106,14 +106,4 @@ If/when this platform is built, the first app I'll build in it is a build-your-o
106106

107107
[1] - "All people" is a strong phrase. Apparently 77% of Wikipedia is written by 1% of editors - and that's not even counting users. The difference with software is that people will want to customize it for themselves, while Wikipedia is for a general audience, so there's less motivation to edit it.
108108

109-
<script>
110-
111-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
112-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
113-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
114-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
115-
116-
ga('create', 'UA-103157758-1', 'auto');
117-
ga('send', 'pageview');
118-
119-
</script>
109+
{% include analytics.html %}

drafts/app-idea.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,5 @@ https://lwn.net/Articles/712376/
3838
[2] Yes, you could submit a pull request, but let’s assume the feature you’re adding is not broadly applicable, so not all users of the service would want it.
3939

4040

41-
<script>
42-
43-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
44-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
45-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
46-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
47-
48-
ga('create', 'UA-103157758-1', 'auto');
49-
ga('send', 'pageview');
50-
51-
</script>
41+
{% include analytics.html %}
5242

drafts/boundaries.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,5 @@ understandability is also key
2525
## security
2626

2727

28-
<script>
29-
30-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
31-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
32-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
33-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
34-
35-
ga('create', 'UA-103157758-1', 'auto');
36-
ga('send', 'pageview');
37-
38-
</script>
28+
{% include analytics.html %}
3929

drafts/casual.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -161,15 +161,5 @@ So if we’re looking to understand a piece of state, we’re not much better of
161161

162162

163163

164-
<script>
165-
166-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
167-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
168-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
169-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
170-
171-
ga('create', 'UA-103157758-1', 'auto');
172-
ga('send', 'pageview');
173-
174-
</script>
164+
{% include analytics.html %}
175165

drafts/invented-or-discovered.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,4 @@ We learn about everything and everyone through construction. We, ourselves, are
3737

3838

3939

40-
<script>
41-
42-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
43-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
44-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
45-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
46-
47-
ga('create', 'UA-103157758-1', 'auto');
48-
ga('send', 'pageview');
49-
50-
</script>
40+
{% include analytics.html %}

drafts/learnable-programming.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,5 @@ Microsoft Excel. Unless you're coming from an accounting background, the grid mo
4545
1. Familiarity of model (is it a human model or comptuer model)
4646
2. Power of model (does it enable powerful ways of thinking)
4747

48-
<script>
49-
50-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
51-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
52-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
53-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
54-
55-
ga('create', 'UA-103157758-1', 'auto');
56-
ga('send', 'pageview');
57-
58-
</script>
48+
{% include analytics.html %}
5949

drafts/power.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,5 @@ I know what you're thinking. "Ok, I agree this is a beautiful vision, but how do
4646

4747
Stay tuned. I have a few ideas on how we can get there. Spoiler alert: interpreted functional (reactive) programming with live visualizations.
4848

49-
<script>
50-
51-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
52-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
53-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
54-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
55-
56-
ga('create', 'UA-103157758-1', 'auto');
57-
ga('send', 'pageview');
58-
59-
</script>
49+
{% include analytics.html %}
6050

drafts/regex-for-humans.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,5 @@ However, I'd really want to think through if this would make this library easier
2727
In conclusion, while this project seems like a neat way to show off my Bret Victor inspiration, I'm not sure who has what problem, and if this semi-proposed solution would solve it.
2828

2929

30-
<script>
31-
32-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
33-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
34-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
35-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
36-
37-
ga('create', 'UA-103157758-1', 'auto');
38-
ga('send', 'pageview');
39-
40-
</script>
30+
{% include analytics.html %}
4131

drafts/visual.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,5 @@ And a way to edit the apps you're using, as use use them. (This will be a challe
102102

103103
You can follow the progress on futureofcoding.org/log and I'm always looking for collaborators.
104104

105-
<script>
106-
107-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
108-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
109-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
110-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
111-
112-
ga('create', 'UA-103157758-1', 'auto');
113-
ga('send', 'pageview');
114-
115-
</script>
105+
{% include analytics.html %}
116106

0 commit comments

Comments
 (0)