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

essays/sissies.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,5 @@ While we all share the same basic assumptions about how programming can be impro
5454

5555
And then I step out of this vibrant online community and into a party in the physical world and Dave just doesn't get it, and I've forgotten how to get Dave.
5656

57-
<script>
58-
59-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
60-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
61-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
62-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
63-
64-
ga('create', 'UA-103157758-1', 'auto');
65-
ga('send', 'pageview');
66-
67-
</script>
57+
{% include analytics.html %}
6858

ideas.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,5 +68,4 @@ title: Research Ideas
6868

6969
* community where you pair near-peers together to learn together (no money making)
7070

71-
72-
71+
{% include analytics.html %}

notes/aaron-kent-call-9-15-17.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,4 @@ title: Aaron Kent Call 9/15/17
3131
* graph.cool
3232

3333

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

notes/aidan-cunniffe-call-11-29-17.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,4 @@
1919
* whole company will be open source
2020

2121

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

notes/andre-staltz-call-10-9-17.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -231,14 +231,4 @@ Notes
231231
- Marinate in problem
232232
- Think through solutions
233233

234-
<script>
235-
236-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
237-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
238-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
239-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
240-
241-
ga('create', 'UA-103157758-1', 'auto');
242-
ga('send', 'pageview');
243-
244-
</script>
234+
{% include analytics.html %}

notes/andre-staltz-call-9-11-17.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,4 @@
118118
* readme has more info on getting started
119119

120120

121-
<script>
122-
123-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
124-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
125-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
126-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
127-
128-
ga('create', 'UA-103157758-1', 'auto');
129-
ga('send', 'pageview');
130-
131-
</script>
121+
{% include analytics.html %}

notes/bret-victor/SimulationAsAPracticalTool.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,4 @@ Solving this problem for "adults" is more interesting.
1919
2020
I wonder if the Mathmatica Langauge is the best solution we currently have to this problem?
2121

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

notes/bret-victor/dynamicland.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -307,14 +307,4 @@ Bret also referenced "shit crayons" a lot. I'm glad I read that piece.
307307
308308

309309

310-
<script>
311-
312-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
313-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
314-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
315-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
316-
317-
ga('create', 'UA-103157758-1', 'auto');
318-
ga('send', 'pageview');
319-
320-
</script>
310+
{% include analytics.html %}

notes/bret-victor/explorable-explanations.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,4 @@ Wow, this is quite similar to my LogicHub idea.
3131

3232
This tools like a really neat tool to build interactive fiction: http://inform7.com
3333

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

notes/bret-victor/index.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -244,15 +244,5 @@ Haven't read.
244244

245245

246246

247-
<script>
248-
249-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
250-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
251-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
252-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
253-
254-
ga('create', 'UA-103157758-1', 'auto');
255-
ga('send', 'pageview');
256-
257-
</script>
247+
{% include analytics.html %}
258248

notes/bret-victor/kill-math.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -151,14 +151,4 @@ There are a few things that Evan misses:
151151

152152
Finally, Evan scores a nice shot on BV by pointing out that he hides the underlying formula in his Explorable Explanation article. Yet this criticism rings false as he's criticizing the same guy who made [TenBrighterIdeas](http://worrydream.com/TenBrighterIdeas/) which allows you to see the entire model as well as edit the actual source code.
153153

154-
<script>
155-
156-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
157-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
158-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
159-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
160-
161-
ga('create', 'UA-103157758-1', 'auto');
162-
ga('send', 'pageview');
163-
164-
</script>
154+
{% include analytics.html %}

notes/bret-victor/learnable-programming.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -379,15 +379,5 @@ But I will say that I got a lot out of this. It's difficult to imagine a world w
379379
This is less related to this particular essay, but... I'm also beginning to detect a communication style that Bret (and others in social activism) use that is compelling (because it plays off of our favorite emotion: outrage), but not helpful for solving problems. It makes me wonder where the "get up and go" to persue a social cause comes from, if not from outrage (or the desire to be right, or to achieve high status). That is, I am theorizing that people with social causes are *less*, not more, concerned with the happiness of other people, despite them purporting to work on their behalf. If they were truly interested in the needs of other people, why not help people in the terms which they want to be helped?
380380

381381

382-
<script>
383-
384-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
385-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
386-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
387-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
388-
389-
ga('create', 'UA-103157758-1', 'auto');
390-
ga('send', 'pageview');
391-
392-
</script>
382+
{% include analytics.html %}
393383

notes/bret-victor/magic-ink.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -171,14 +171,4 @@ Recursion, instead of iteration like Excel has for programming by example repeti
171171
This is profound for the building of user interface builders. What if interactivity is overrated, and instead we should design to empower the creation of information software. I guess Webflow does this best.
172172

173173

174-
<script>
175-
176-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
177-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
178-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
179-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
180-
181-
ga('create', 'UA-103157758-1', 'auto');
182-
ga('send', 'pageview');
183-
184-
</script>
174+
{% include analytics.html %}

notes/bret-victor/questions.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,5 @@ How do square your admiration for functional programming with your desire to "ki
1111

1212
You often reference, directly or indirectly, how many of the principles of functional programming could improve programming generally. Yet few, if any, of your talks, papers, or demos, seem to embody those principles. Why is this?
1313

14-
<script>
15-
16-
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
17-
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
18-
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
19-
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
20-
21-
ga('create', 'UA-103157758-1', 'auto');
22-
ga('send', 'pageview');
23-
24-
</script>
14+
{% include analytics.html %}
2515

notes/bret-victor/substroke.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,4 @@ This was much easier for me to understand and feels similar.
1919

2020
### [Vogo](mgrf.de/vogo/)
2121

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

0 commit comments

Comments
 (0)