Skip to content

armgit / umami

Public Imported from GitHub
0

Umami is a privacy-first web and product analytics platform. Traffic, campaigns, behavior, conversions, and revenue in one place. No cookies, no surveillance, self-hosted or in the cloud.

Add keepalive option to tracker fetch request

Sov3rain42c0ccc2eb6c
diff --git a/src/tracker/index.js b/src/tracker/index.js
index 905ba4344..76d29a1dd 100644
--- a/src/tracker/index.js
+++ b/src/tracker/index.js
@@ -150,6 +150,7 @@
try {
const res = await fetch(endpoint, {
+ keepalive: true,
method: 'POST',
body: JSON.stringify({ type, payload }),
headers: {