From 28f8447a8fed594da4e03d9303ad569eb6e64ce8 Mon Sep 17 00:00:00 2001 From: Kumungchi Date: Sun, 19 May 2024 16:47:08 +0200 Subject: [PATCH] Added google analytics for user checking of the project --- index.html | 1 + script.js | 2 ++ 2 files changed, 3 insertions(+) diff --git a/index.html b/index.html index fe01df8..082e39e 100644 --- a/index.html +++ b/index.html @@ -7,6 +7,7 @@ + diff --git a/script.js b/script.js index 3971463..9cdb1ff 100644 --- a/script.js +++ b/script.js @@ -1,5 +1,6 @@ // Import Firebase modules from CDN import { initializeApp } from "https://www.gstatic.com/firebasejs/10.12.0/firebase-app.js"; +import { getAnalytics, logEvent } from "https://www.gstatic.com/firebasejs/10.12.0/firebase-analytics.js"; import { getFirestore, collection, getDocs, updateDoc, increment, arrayUnion, doc, getDoc } from "https://www.gstatic.com/firebasejs/10.12.0/firebase-firestore.js"; // Firebase configuration @@ -15,6 +16,7 @@ const firebaseConfig = { // Initialize Firebase and Firestore const app = initializeApp(firebaseConfig); +const analytics = getAnalytics(app); const db = getFirestore(app); let currentWordIndex = 0;