Skip to content

Commit 751aec2

Browse files
committed
fix(analytics): initialize seline for user tracking
1 parent 8fff099 commit 751aec2

2 files changed

Lines changed: 15 additions & 1 deletion

File tree

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
darkMode: 'class',
1111
}
1212
</script>
13+
<script async src="https://cdn.seline.com/seline.js" data-token="091747081ed47e6"></script>
1314
<script src="js/main.js"></script>
1415
<script src="js/theme.js" defer></script>
15-
<script async src="https://cdn.seline.com/seline.js" data-token="091747081ed47e6"></script>
1616

1717
<link rel="icon" type="image/png" href="assets/favicons/favicon-96x96.png" sizes="96x96" />
1818
<link rel="icon" type="image/svg+xml" href="assets/favicons/favicon.svg" />

js/main.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
// --- Seline Analytics ---
2+
function initSeline() {
3+
if (typeof seline !== "undefined") {
4+
seline.init({
5+
token: "091747081ed47e6",
6+
autoPageView: true
7+
});
8+
console.log("Seline initialized");
9+
} else {
10+
setTimeout(initSeline, 100);
11+
}
12+
}
13+
document.addEventListener("DOMContentLoaded", initSeline);
14+
115
function scrollToMission() {
216
document.getElementById('mission').scrollIntoView({
317
behavior: 'smooth'

0 commit comments

Comments
 (0)