Switched to plausible-tracker and removed node-fetch

This commit is contained in:
Mawoka
2022-06-24 14:02:23 +02:00
parent cc33f16d6f
commit c19e362aaf
10 changed files with 59 additions and 100 deletions
+7
View File
@@ -8,6 +8,7 @@ export const alertModal = writable({ open: false, title: '', body: '' });
import { goto } from '$app/navigation';
import { page } from '$app/stores';
import Plausible from 'plausible-tracker';
const URLSearchParamsToObject = (params: URLSearchParams) => {
const obj = {};
@@ -41,3 +42,9 @@ export const createQueryParamsStore = (key: string) => {
}
};
};
export const plausible = Plausible({
domain: 'classquiz.mawoka.eu',
apiHost: 'https://sugar.mawoka.eu.org',
trackLocalhost: true
});