mirror of
https://github.com/umami-software/umami.git
synced 2026-02-22 21:45:36 +01:00
Update index.js
trigger only after document readstate change to complete
This commit is contained in:
parent
cb790fd466
commit
72bc3299e2
1 changed files with 8 additions and 6 deletions
|
|
@ -223,6 +223,7 @@
|
|||
};
|
||||
|
||||
const init = () => {
|
||||
if(document.readyState==='complete'){
|
||||
if (!initialized) {
|
||||
track();
|
||||
handlePathChanges();
|
||||
|
|
@ -230,6 +231,7 @@
|
|||
handleClicks();
|
||||
initialized = true;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const track = (obj, data) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue