Skip to content

Commit

Permalink
remove cabin in favor of bearlytics
Browse files Browse the repository at this point in the history
  • Loading branch information
jbowdre committed Dec 1, 2024
1 parent c3dedda commit 635cc59
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 50 deletions.
5 changes: 4 additions & 1 deletion content/changelog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "/changelog"
date: "2024-05-26T21:19:08Z"
lastmod: "2024-10-20T03:51:49Z"
lastmod: "2024-12-01T22:56:07Z"
description: "Maybe I should keep a log of all my site-related tinkering?"
featured: false
toc: false
Expand All @@ -10,6 +10,9 @@ categories: slashes
---
*Running list of config/layout changes to the site. The full changelog is of course [on GitHub](https://github.com/jbowdre/runtimeterror/commits/main/).*

**2024-12-01:**
- Switch from Cabin analytics to lightweight-and-self-hosted [Bearlytics](https://github.com/HermanMartinus/bearlytics)

**2024-10-19:**
- Shut down Gemini mirror, removed links pointing to it

Expand Down
8 changes: 5 additions & 3 deletions content/posts/kudos-with-cabin/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "Kudos With Cabin"
date: 2024-06-24
lastmod: "2024-06-26T02:13:13Z"
lastmod: "2024-12-01T22:49:24Z"
description: "Using Cabin's event tracking to add a simple post upvote widget to my Hugo site."
featured: false
toc: true
Expand All @@ -14,6 +14,10 @@ tags:
- selfhosting
---

{{% notice note "Closing my Cabin" %}}
I've switched to a different [self-hosted analytics provider](https://github.com/HermanMartinus/bearlytics). It's much more minimal and lightweight, but doesn't (yet?) support event tracking so I've removed the kudos button from the blog. This post will remain in case anyone else wants to do something similar with Cabin.
{{% /notice %}}

I'm not one to really worry about page view metrics, but I do like to see which of my posts attract the most attention - and where that attention might be coming from. That insight has allowed me to find new blogs and sites that have linked to mine, and has tipped me off that maybe I should update that four-year-old post that's suddenly getting renewed traffic from Reddit.

In my quest for such knowledge, last week I switched my various web properties back to using [Cabin](https://withcabin.com/) for "privacy-first, carbon conscious web analytics". I really like how lightweight and deliberately minimal Cabin is, and the portal does a great job of presenting the information that I care about. With this change, though, I gave up the cute little upvote widgets provided by the previous analytics platform.
Expand Down Expand Up @@ -181,5 +185,3 @@ You might have noticed that I'm not doing anything to display the upvote count o

In any case, after clicking the 👍 button on a few pages I can see the `kudos` events recorded in my [Cabin portal](https://l.runtimeterror.dev/rterror-stats):
![A few hits against the 'kudos' event](kudos-in-cabin.png)

Go on, try it out:
7 changes: 0 additions & 7 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,6 @@
{{- end }}
{{- if eq $reply true }}
<hr>
<div class="kudos-container">
<button class="kudos-button">
<span class="emoji">👍</span>
</button>
<span class="kudos-text">Enjoyed this?</span>
</div>
<script src="https://res.runtimeterror.dev/js/kudos.js" async></script>
<span class="post_email_reply"><a href="mailto:wheel.east.brief@clkdmail.com?Subject=Re: {{ .Title }}">📧 Reply by email</a></span>
{{- end }}
<footer class="content__footer"></footer>
Expand Down
2 changes: 0 additions & 2 deletions layouts/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,6 @@
<link rel="license" href="https://creativecommons.org/licenses/by-nc-sa/4.0/">

{{ if eq .Site.Params.analytics true }}
<!-- cabin analytics -->
<script async src="https://cabin.runtimeterror.dev/hello.js"></script>
<!-- bearlytics -->
<script data-site="ZHFGHYJ" src="https://bearlytics.runtimeterror.dev/script.js" async></script>
{{ end }}
Expand Down
37 changes: 0 additions & 37 deletions static/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -490,43 +490,6 @@ p:has(+ ul) {
}
}

/* Cabin kudos styling */
.kudos-container {
display: flex;
align-items: center;
}

.kudos-button {
background: none;
border: none;
cursor: pointer;
font-size: 1.2rem;
padding: 0;
margin-right: 0.25rem;
}

.kudos-button:disabled {
cursor: default;
color: var(--fg);
}

.kudos-button .emoji {
display: inline-block;
transition: transform 0.3s ease;
}

.kudos-button.clicked .emoji {
transform: rotate(360deg);
}

.kudos-text {
transition: font-style 0.3s ease;
}

.kudos-text.thanks {
font-style: italic;
}

/* Header anchor links */
.hlink {
opacity: 0.4;
Expand Down

0 comments on commit 635cc59

Please sign in to comment.